Bear in mind that if someone did attack your device with a strong magnet, the best they could do is scramble or wipe the data. They couldn't actually steal anything from you.
As others have said, this kind of attack is fairly low risk. However, if you are really concerned about it, the thing you are looking for is a
Faraday cage, which essentially shields anything inside it from electromagnetic fields or charges. Some bank vaults have these built in, and there are also ones you can buy yourself, either as a stand alone box or built in to a home safe or vault.