Without letting us know the exact make and model your washing machine, it's not possible to provide an accurate answer to your question.
Might be worth pulling the power plug from the wall for a minute, then plug it back in and run a short spin cycle to see if door releases when that spin has finished.
You say the door is not broken, but have you considered that the electronic door latch inside the machine has failed as they often do. (especially Zanussi/Indeshit/Hoover)
A last resort, if you need to get your washing out. is to gently lever the door open with a suitable tool whilst pulling the release handle - this will allow the door to pull free from the lock without doing major damage - if you do it carefully. This in turn will allow you to gain access to the latch in the machine and replace with a new part. Above advice is general and may not work with whatever machine you own.
Rupert
January 2020