How do I understand which page of my theme is being loaded?

If it’s just for your understanding, then install the Query Monitor plugin, which gives you a lot of information about what’s going on under the hood