A magnetic lock will be based on a solenoid, which will probably draw quite a high current from the 12 V rail. When that load is switched, a voltage spike will appear into the 12V rail due to the inductance of the supply wires. The longer the wires and the higher the current, the bigger the voltage spike.
simulate this circuit – Schematic created using CircuitLab
If the spike goes above 20V (and it can easily happen, believe me) then it will exceed the maximum rating of the MIC5205 voltage regulator and fry it unless you prevent that with some extra components. The voltage rating of the regulator input capacitor in the Pro Mini probably isn't up to the task of handling 20+ V spikes either and may be getting damaged too.
Note that the Pro Mini is specified to work with input voltages only up to 12 V, so you are operating it with no margin whatsoever! You should consider reducing that voltage in first place. You could use a DC/DC converter module to step down the 12V to a more suitable 7V and provide isolation from the spikes at the same time.
Apart from that, consider using a transient voltage suppressor (TVS or transzorb diode) and/or a large decoupling capacitor (with an adequate voltage rating) as close as possible to the input of the Pro Mini or the DC/DC converter (if you use one). You might want to try decoupling your magnetic lock with a properly selected capacitor as well.
Bonus: thermal considerations
Thermal issues shouldn't be the main culprit here, but be aware that the tiny MIC5205 can get extremely hot and enter thermal shutdown mode when operated at 12 V input voltage.
The junction to ambient thermal resistance of the regulator is 220 C/W. Its maximum operating junction temperature is 125 C. At 25 C ambient temperature that means the maximum allowable temperature rise is 100 C and the maximum allowable power dissipation is 455 mW. Because the regulator is dropping 7V, the maximum allowable current will be only 65 mA (instead of the 150 mA max that the MIC5205 can source in more favorable conditions). The consumption of the Pro Mini is around 20 mA, so that leaves you with only 45 mA for your application. You should consider whether this is enough for your application or not (some 5V relays draw around 80 mA, which will greatly exceed this 45 mA calculated limit, when connected to the VCC pin of the Pro Mini).