Check out example codes for "how to access gameobject name". It will help you in understanding the concepts better.
Code Example 1
// note how the 'g' is lowercase, when it's lowercase it accesses the GameObject its attached to gameObject.name // so if this script was attached an object named "Player", it will access "Player"
Code Example 2
GameObject.name = "Ben";
Learn ReactJs, React Native from akashmittal.com