A failed military coup in Turkey will give President Tayyip Erdogan the opportunity to intensify his crackdown on dissenters, analysts say.