Phase transitions and the magnetocaloric effect in Mn rich Ni–Mn–Ga Heusler alloys