New Zealand says it will keep its small contingent of troops in Iraq for an additional 18 months as it continues to back the U.S.-led coalition's efforts to defeat the Islamic State group.

Last year, New Zealand deployed 143 military personnel on a two-year mission to train Iraqi security forces. That mission was due to end next May, but Prime Minister John Key said Monday that the troops would now stay until November 2018.

Key said the mission would be altered. The New Zealand troops will now be authorized to train Iraqi police as well as the army, as Iraq tries to hold onto recent territory gains over IS.

Iraqi forces on Saturday gained control of the main hospital in Fallujah after driving militants from most of the city.