Usually, heat flows from a hot place to a cold place, according to the second law of thermodynamics. Heat will not move from a cold place to a warmer place by itself. Because of this, a heat pump must use extra energy to move the heat. This is sort of like pumping water uphill.