A student reacts in front of the Raul Brasil school after a shooting in Suzano, Sao Paulo state, Brazil March 13, 2019.
The shooting happened at about 09:30 local time (12:30 GMT) when the students were in a break at the state school in Suzano, near São Paulo.
Another ten people, mostly schoolchildren, were shot and injured, and several were in serious condition, said police, who lowered their estimates for the number of children killed and those injured late on Wednesday afternoon.
The assailants reportedly were former students of the school, yet the motive of the attack remains unclear.
Doria said the school had been evacuated and police were inspecting possible explosives left by the shooters.
"We were at recess and eating like normal, and we heard three pops, then we tried to run to jump over the walls", Rosni Marcelo Grotliwed, 15, told G1 news portal.
Television pictures showed anxious family members congregating outside the Raul Brasil school in the greater Sao Paulo area, alongside firefighters and security services.
"My friend was stabbed in the shoulder and my other friend was shot", she said.
Horacio Pereira Nunes, a retiree whose house is next to the school, said he began hearing shots around 10 a.m. "It didn't take long until police arrived".
The two adolescent attackers, who were wearing face masks, killed themselves after the rampage, officials said.
The unidentified gunmen, who appeared to be between 20 and 25 years of age, shot and killed a worker at a nearby vehicle wash before their attack at the Raul Brasil school, police said.
Despite Brazil being one of the world's most violent countries, school shootings are rare.
However, current Brazilian President Jair Bolsonaro signed a temporary decree in January that made it easier for citizens to buy guns in an effort to overturn the strict regulations of the past.