No, the door interlock is an important safety feature, after a young boy had his arm removed by a spinning washing machine. You have to fix it, not bypass it. My guess is that is is badly adjusted and the lock is not fully closing to trigger the microswitch. You can just join the wires together, but that might cause further problems. All these machines are electronic and the have 'what is happening? What do I do now?' logic. you can try it, but not if you have kids please.
There are videos here. Watch them and see if you did it right and if they have information on adjustment?