Which M3 screw / bolt material can be used in dishwasher?
You want stainless steel

That should be readily available in any hardware store that sells metric.  Stainless + metric both can be a little bit specialty, so you need that community hardware store that's been around for 100 years, or McMaster-Carr or equivalent in your territory.