Shouldn't "The students write at school" also be allowed? After all "at school" in English is not literally next to the school, but more like "inside the school building or institution".
Agreed. The at in this case signifies whilst attending. I think that US English tends to use in where the UK uses at:
UK: I learnt that at school
US: I learnt that in school
Since this is an intenational platform, both should be accepted.