Comparing the strength of metallic bonds
There are two main reasons:


Metallic bonding is more prevalent for transition metal elements because there are more electrons available for delocalization (from s and d orbitals), while Magnesium has only s electrons
Fe has a higher atomic mass than Mg --> van der Waals forces are stronger.