Hail forms when its is A. SUPER cold and B they first have to accumulate into raindrops and then freeze, so basically they water molecules are just forming into regular rain and then the temperature suddenly drops the raindrops freeze and turn into hailstones.
Hope that helps!