Washing machines vibrate, even if they are set up properly if you spin a load of towels it will want to go for a walk.
Old washers had thumping great lumps of concrete fixed inside the cabinet and weighed a lot. Modern ones (as in last 20 years or so) don't, they normally have lightweight dampers between drum mechanism and chassis which work fine but the lighter weight means the cabinet is more likely to want to move.
Boxing in strikes me as bonkers, all my white goods are simply floor standing in 60cm wide under counter spaces, they look fine and it's easy to access and replace - a good kitchen will last far longer than an appliance. You also need access round the back from time to time to check or deal with leaks and drips and maybe clear the water inlet filter, and of course empty and clean the pump filter which on most is very low down at the front.
My sister in law moved into a house with a fancy all-enclosed fitted kitchen, washer, fridge freezer all well shot and it was a real pain and extra expense to source things of the exact right dimensions, fit them and get all the door covers etc. working properly. Grrrr.
I did once raise a washing machine when my ageing mother had trouble bending down - a few inches made all the difference. I used 4 concrete blocks laid on their side as a base. Maybe you could do that - bottomless cupboard and a plinth to hide the blocks.
Better still, instead if building a cabinet, offer to train them in industrial design appreciation so they value the functional beauty of good washing machine. Hiding in cupboards is so last century.