GMRT radio halo survey in galaxy clusters at z = 0.2–0.4 - I. The REFLEX sub-sample