@Ioanna Kambouroudis You will need to reach out to your school's IT department. It sounds like they have blocked your device from logging onto your account.
This is outside Microsoft's control, and you'll need to reach out to your school's IT department directly to resolve this.