Depending on your washer door these style of locks work well

Came here to say this. We have these everywhere in the house. They’re super easy to open (by adults) and should come off when the kiddos are older without too much fuss.

Will get mouldy and gross inside.

Someone else mentioned a specialised product like this:

www.amazon.com.au/dp/B0B4R7NK9V/ref=sspa_mw_detail_1?ie=UTF8&psc=1&sp_csd=d2lkZ2V0TmFtZT1zcF9waG9uZV9kZXRhaWwp13NParams