Would it not be possible to have a box at the front of the room that everyone has to put their phone in when they come to class, then they can get it back after class is over?
If anyone's ever been in a secure facility, they have little mail slots, sometimes locking with a key you can take, to store your phone while you go inside. Seems like we could just put one of these in every classroom. That should take care of the liability issue.