"Such attacks, if deliberate, may amount to war crimes," Ban said in a statement. Syrian state media reported that rebel rocket fire had hit a school in west Aleppo.
The city has been divided since mid-2012, when rebels seized its eastern half.
"Three children were killed and 14 students were injured in a terrorist rocket attack on the national school in the Shahba neighbourhood of Aleppo," state news agency SANA reported from Damascus.
The UN chief renewed his call to the Security Council to ask the International Criminal Court to investigate allegations of war crimes in Syria. "Those responsible for these acts must be brought to justice," he said.
Regime forces backed by ally Russia have waged an aerial and ground assault since late September to recapture eastern Aleppo, killing hundreds of civilians and destroying infrastructure including hospitals.
On Wednesday, the UN children's agency UNICEF said 22 children had been killed along with six teachers in air strikes on a school in rebel-held Idlib province.
Ban said he was appalled by that attack and demanded an immediate investigation after warning that the assault on the school could amount to a war crime.
The UN chief has repeatedly urged the Security Council to formally request that the ICC begin war crimes investigations in Syria. Such a request was blocked in 2014 by Russia and China, which have veto powers.
The 15-member council has the authority to refer a country to the Hague-based ICC for war crimes investigations as it has done for Libya and Sudan's troubled Darfur region.
More than 300,000 people have been killed in Syria and over half of the country's population displaced since the conflict began in March 2011 with anti-government protests.