An Iraqi warplane has accidentally dropped a bomb over a residential area of Baghdad after it experienced mechanical failure, according to the country's defence ministry.

Officials confirmed to Al Jazeera on Monday that a bomb fell from a Russian-made Sukhoi Su-25 fighter jet, hitting a the New Baghdad neighbourhood of the city and leaving 12 people killed or wounded.

Early reports suggested at least seven of the casualties had been killed.

"One of the bombs became stuck because of a technical problem, and during its [the aircraft's] return to base it fell on three houses in Baghdad Jadida," security spokesman Brigadier General Saad Maan said in a statement.

The jet was coming back from a bombing run when the accident occurred, Maan said, according to the AFP news agency.

Iraq received Sukhoi Su-25 jets from Russia and Iran last year as it sought to bolster its fledgling air force to combat the Islamic State of Iraq and the Levant (ISIL) group, which has seized large parts of the country.

The US agreed to sell Iraq 36 F-16 warplanes, but none have been delivered so far.

The first batch of the jets has instead been sent to Arizona, where Iraqi F-16 pilots are training.

One of pilots was killed in a crash during an aerial refuelling exercise at the end of June.