|By Samia Nakhoul, Nick Tattersall and Orhan Coskun

|By Samia Nakhoul, Nick Tattersall and Orhan Coskun

ANKARA (Reuters) - Turkish President Tayyip Erdogan told Reuters on Thursday that there were significant intelligence failures ahead of last week's attempted military coup and that the armed forces would quickly be restructured and have "fresh blood".

In his first interview since declaring a state of emergency following last Friday's abortive coup, Erdogan said a new coup attempt was possible, but would not be easy, saying "we are more vigilant".

"It is very clear that there were significant gaps and deficiencies in our intelligence, there is no point trying to hide it or deny it. I told it to the head of national intelligence," Erdogan told Reuters in his palace in Ankara, which was targeted during the coup attempt.

Erdogan accuses Fethullah Gulen, a charismatic U.S.-based cleric and former ally, of masterminding the plot, which crumbled early on Saturday. In a crackdown on Gulen's suspected followers, more than 60,000 soldiers, police, judges, civil servants and educators have been suspended, detained or placed under investigation.

Erdogan said a meeting of the Supreme Military Council (YAS), the top body overseeing the armed forces, which had been due on Aug. 1, may be brought forward by a week to oversee the restructuring. The Council is chaired by the prime minister, and includes the defence minister and the chief of staff.

"They are all working together as to what might be done, and ... within a very short amount of time a new structure will be emerging. With this new structure, I believe the armed forces will get fresh blood," Erdogan said.

"After all that has come to pass, I think they must now have drawn very important lessons. This is an ongoing process, we will never stop, we will continue very actively, we have plans."

Erdogan, the most dominant political figure on the Turkish stage since Mustafa Kemal Ataturk, founder of the modern republic, and who has had a winning streak of more than 10 election victories, has been at war with his former ally for several years.

Asked whether the abortive coup had derailed his plans to change the constitution and bolster his powers by making Turkey a full presidential system, he avoided a direct answer, but said a "more limited" package of constitutional amendments could be agreed with the opposition.

He said the fact that some of members of parliament had not voted in favour of the state of emergency, despite the difficulties in the country, was "food for thought", and showed the need for building consensus with opposition parties.

"If we can achieve consensus ... we might take it to the people in the form of a referendum", he said of a possible package on constitutional reforms.

INITIAL DISBELIEF

Erdogan said there was no obstacle to extending the state of emergency beyond the initial three months if necessary. It would allow his government to take swift measures against supporters of the coup and will permit the president and cabinet to bypass parliament in enacting new laws and to limit or suspend rights and freedoms as they deem necessary.

"This state of emergency is not a curfew. People will still be on the street minding their own business and getting on with daily life", he said.

He looked calm and composed throughout the interview, but security was heightened inside and out his vast palace complex, with police special forces in the gardens and city dump trucks blocking access roads at impromptu checkpoints.

The lights at the palace, which usually illuminate the night sky, have been dimmed in recent days.

Erdogan, describing how events unfolded on the night of the coup attempt, while he was on holiday with his family near the coastal resort of Marmaris, he said he had initially not believed a phone call from his brother-in-law informing him that soldiers had started blocking streets in Istanbul.

He was initially unable to reach the head of the armed forces or the head of the national intelligence agency, and after some difficulty was able to contact the prime minister, he said.

After appealing to supporters by dialling in to broadcasters on a cellphone, Erdogan received reports that people were taking to the streets and decided he needed to move.

"It became clear to me that I had to move, it was no longer necessary for me to stay put", he said. He and his family took his plane back toward Istanbul, but the airport was under attack and the lights on the landing strip had gone off.

"I was talking to our pilot, asking questions about the situation of the airport ... I asked him how much fuel he had, and he told me he had enough to keep us airborne for three or four hours", Erdogan said.

Erdogan landed after loyalist forces took back the airport control tower and secured the runway. Asked if he had been afraid to take to the skies as the coup plot unfolded, he said he believed in destiny.

"Having faith is one of the conditions of being a Muslim", he said. "My wife, daughter, grandchildren, my son-in-law, my security detail - everybody was in the plane ... Allah apparently decided for us to continue and not to perish that night".

'INHUMAN AND IMMORAL'

The Gulen movement would be treated as "another separatist terrorist organisation", he said, drawing a parallel to Turkey's fight against Kurdish militants over the past three decades.

"We will continue the fight ... wherever they might be. These people have infiltrated the state organisation in this country and they rebelled against the state," he said, calling the actions of Friday night "inhuman" and "immoral".

He compared the Gulen movement to a malignant cancer in the body that could spread and return if not eliminated.

"We will do everything necessary to have the highest rate of success ... whatever the law allows or admits", he said, adding that his ruling Justice and Development Party (AKP) had at one stage helped the Gulen movement, but had been betrayed.

"We never considered even the possibility that they might be involved in this kind of a treason ... We supported them to the fullest as citizens of our country", he said.

"They are traitors ... They have always been two-faced, if you want, and now we see their real face very clearly".

The authorities have said they will seek the extradition of Gulen, who has denounced the coup attempt and denied any involvement, suggesting it may have been staged by Erdogan as an excuse to crack down on the religious movement.

The putsch and the purge that has followed have rattled the country of 80 million, a NATO member bordering Syria, Iraq and Iran, and a Western ally in the fight against Islamic State.

Erdogan said the death toll had risen to 246 people excluding the coup plotters and that 2,185 people were wounded. Soldiers used fighters jets, military helicopters and tanks to strike government institutions including parliament, the intelligence agency and Erdogan's palace in Friday's violence in Istanbul and Ankara.

The Turkish president said a cut in Turkey's foreign currency credit rating by Standard & Poor's had been a political decision and showed the credit ratings agency had "sided with the coup, not with democracy".

He also said that if rival ratings agency Moody's Investors Service followed suit, it would not be an objective decision, adding that there was no liquidity problem in Turkey's strong financial sector.