The messages app comes as part of whatever OS was on the computer originally. It is not just a simple install of the app. You will need to reinstall the OS as new. Here is a guide by Apple on how to restore your OS to new.
Would you not be able to take it to the schools IT support and get them to remove the restriction? If they can do that, then iMessage should be reenabled.