What Mamata shows you is not what you're looking for.
Objects do not have names, so it is not possible to get the "name" of an object.
What you think is the name of the object, is just the name of a reference variable that refers to the object. Note that there can be multiple variables that refer to the same object. What would be the "name of the object" in that case?