Local schools get this power from the State governments, as it is under these institutions powers to oversee all matters related to education and taxation within its borders. The tax rate varies according to the state. However, this is a common practice among the current states.
It does make sense to handle it at a local level because the social and economic realities of each state vary. Therefore, this matter would be seen at a federal level, it would not be as effective.