Maytag washer door doesn't stay closed

Our Maytag washer door doesn’t stay closed. It has opened during the wash cycle a couple of times and flooded our room. In order to close it and use it we have to slam it closed. Today that didn’t work and it opened again. Not sure what to do. It looks like the top of the door is closed but the lower portion doesn’t appear closed well. Any idea how to fix this? Thanks

Hard to say, it could be the door lock assembly or the control unit but from your description it may be that the door itself is out of whack and will not close correctly. This is a fairly troubled model and you may want to replace it.