Turkey has identified the gunman in the Istanbul nightclub massacre, the foreign minister said Wednesday as the president vowed that the country won't surrender to terrorists or become divided. The gunman, who killed 39 people during New Year's celebrations at the Reina club and restaurant, is still at large. But Foreign Minister Mevlut Cavusoglu said authorities had identified the man, without providing details. "The identity of the person who carried out the attack on the Reina nightclub has been established," Cavusoglu told Anadolu in a live televised interview. Turkish police, meanwhile, detained at least five suspected Daesh group militants believed to be linked to the attack, the state-run news agency reported. The operation was launched in the Aegean port city of Izmir and was ongoing, Anadolu Agency said. Daesh has claimed responsibility for the attack, which also wounded nearly 70 people. Of those killed 27 were foreigners, many from the Middle East. D President Recep Tayyip Erdogan said that the attack aims to set Turks against each other and deepen fault lines, but the country won't fall for this game. Erdogan made the comments in a live speech from Ankara, the first time he has publicly addressed the nation since the attack. Erdogan said that "in Turkey, no one's way of life is under any threat. Those who claim this have to prove it. It is my duty to protect everyone's rights." He also said that "to say Turkey has surrendered to terrorism is to take sides with the terrorists and terror organizations." Police in Istanbul have set up checkpoints and are checking vehicles across the city as security levels remained high. Police were stopping cars and Istanbul's ubiquitous yellow taxis, with passengers and drivers holding up their identifications while officers inspected inside the vehicles. Istanbul has been on high alert since the attack, with the gunman still at large. The private Dogan news agency said that Wednesday's police operation targeted three families who had arrived in Izmir about 20 days ago from Konya — a city in central Turkey where the gunman is thought to have been based before carrying out the nightclub attack. It said 27 people, including women and children, were taken into custody.