School shooting, Russia
© UnknownEmergency vehicles parked outside a school in Russian capital Moscow, where a gunman shot dead a police officer and a teacher on February 3, 2014.

Russian police have confirmed that a police officer and a teacher were killed as an armed young man took children hostage at a school in the capital Moscow.

The man armed with a rifle entered the school located in northeast of Moscow on Monday, threatening the school's security guard, the police added.

The security guard managed to contact the police. Upon arrival, the guard showed the officers the biology room where the assailant had taken 20 teenagers aged 15 hostage, most of whom were released shortly afterwards.

The attacker opened fire at the police when they reached the room, killing the officer and wounding another, according to local media.

Authorities said the police officers had detained the gunman, who is reportedly a high school student.

No immediate details were released regarding the death of the teacher.

Students were evacuated from the school while shocked parents had gathered outside the building.

All Russian schools have an armed security guard, according to a law passed in the wake of the 2004 hostage crisis in a school in Beslan, North Ossetia, which led to the deaths of over 330 hostages, many of them children.