When heat is removed from water for example, it turns from a liquid to a gas.
The particles in water absorb this energy, giving them a higher energy level. The particles are able to change state when thermal energy is removed.
----------------------------------------------
Hope this helps!
Have a great day and God bless! :)