there's no way out of the academy until you complete all your classes and get your stamps at the front desk. attend each teacher's 3 classes to get the stamps and unlock the exit.
He had beaten the headmistress (only complete all of the classes you can enter the headmistress').
Did you talk to the new headmaster and get the key?
Edited:I retry this scene again, you can get out except night time. When you back to front door, you face to the blue sheild and press space button,you can come out easily and can go everywhere.