The cupboard can change how sound reaches the room, so a different volume with its door open does not by itself prove a mechanical fault. Compare the appliance's overall behaviour, not just the loudness at your ear.
What the observation tells you
Do not add foam around the motor or pack insulation against components to quieten it. That can obstruct required access and alter the installation. Loose cabinet contents can be checked with the appliance off, without touching its connections.
A useful next step
If the sound itself is new, metallic or accompanied by vibration or poor clearing, request assessment. Describe the cabinet effect as an observation rather than the cause.
Manuals and supporting guidance
Model-specific instructions take priority. These references support the practical principles discussed here; they do not diagnose your appliance.