Heat is absorbed with rise in temperature when change of state is taking place. The configuration of molecules and therefore, the potential energy of the molecules of there is different in two different states say solid and liquid or liquid and gas etc