Here's why this happens:
* Heat flows from hotter to colder objects: Heat is the transfer of thermal energy from one object to another. This transfer happens due to a temperature difference, always moving from the higher temperature object to the lower temperature object.
* Thermal equilibrium = no temperature difference: When objects reach the same temperature, the temperature difference driving the heat transfer disappears. Therefore, no more heat flows between them.
It's important to note that even in thermal equilibrium, the objects may still contain different amounts of internal energy. This depends on their specific heat capacity and mass. For example, a large pot of water at room temperature will have a lot more internal energy than a small metal coin at the same temperature.