(Although, who knows, that might just be a weird localism, just like “Guten Nacht, schlaf gut, träum süß von sauren Gurken.” which I was taught in Köln and nobody else I’ve talked to anywhere in Germany recognises, though when I say I learned it in Köln they all go “Oh, Köln, yeah, they’re all crazy like that”.)
But the general term, as a verb, is "Lüften" or specifically "Stoßlüften" for the shorter form that is often mandatory for apartments with modern insulation but lacking a proper vent system to prevent mold.
On a sidenote: an interesting folk etymology exists for the Rhineland word "Fisimatenten", meaning something like "shenanigans", deriving it from French "visite ma tente", literally "visit my tent": the claim is that mothers would advise their daughters to avoid "Fisimatenten" because French soldiers during the Napolean occupation might invite them (in French) into their tents for, well, shenanigans.
Exactly that.
To add, problems with mold are often due to insufficient insulation in some patches of the wall (like near windows), combined with humid air and insufficient ventilation. A properly insulated house should not form mold. But it is necessary to get humidity out, that's correct.