In the case of the water, only one event occurs that allows the water to absorb energy from its surroundings - the water molecules gain kinetic energy as the water warms in temperature.
On the other hand, the ice gains energy from its surroundings in two ways. First, the phase change must occur. This involves the water molecules breaking out from the crystalline pattern they had in the ice, and liquid water being prouced. Energy absorbed during this period is entirely potential energy, as the molecules' configuration changes. There is no temperature change while this is going on.
Then, the same temperature change energy effect also occurs (the we just considered for the water).
Of the two effects, the phase change is the greater. It absorbs 334 J of energy per gram of ice melted, while the warming of one gram of water from 0°C to 20°C (for example) absorbs only 84 J (and is seen in both situations).