Yes but that usually results in an immediate issue. As soon as you fly away from the magnetic interference the bird gets wonky. I have seen that happen a number of times. My personal compass errors have all occurred during flight and were because of "local" interference. The one below is a sawmill that is 100% metal. This happened with my Phantom 3, I was pretty close. I haven't flown that close with the Mavic so I don't know if the same problem would occur.
Several other times I received a compass error, again P3, was in a remote area. Every time I flew over a certain area I would get a compass error really a weird phenomena. I would be flying out in the desert and when I get near this spot compass error I would keep flying and it would go away. It's a repeatable error. I have no idea why as there was nothing on the ground or nearby that would be an obvious cause of the compass error. Maybe it was electromagnetic ?? No idea.
View attachment 61719