The simplest thing to remember is "for academic purposes, with teacher approval." If you are missing one of those things, assume you cannot use your phone or other technology at all during school hours. If you have both, then you are good. It never hurts to ask a teacher, if in doubt.
During school hours, you are expected to keep your phone put away, unless your teacher gives you permission to use it for a specific activity. Keep in mind, when you are given permission to use it, it's for academic purposes and you are expected to only be working on the class activity (not working while bouncing to another app) and the permission is just for that class activity. When class ends or you switch activites, assume you no longer have permission to use the phone.
If you aren't using the phone for a class, with teacher approval, be aware a teacher is likely to ask for the phone. If you refuse to give it to them, you'll likely have three days out of school suspension. If you give it to them, a parent or legal guardian can get the phone from M office (the main office) the next school day. Repeated phone violations will lead to progressive discipline--though those are going to be less than the punishment for refusing to give up the phone.
You can get the full GHS technology expectations document here.