Islam propagates the idea that the rightful ruler of this world is Allah(SWT) alone. No one else has the right to govern people unless they do it within His defined limit. The humans are sent to this earth as vicegerent (Caliph) to Allah(SWT) to establish His rule and system. When a prophet is present among the people, he is Allah's(SWT) chief vicegerent and once he passes away, the next best person among the muslim nation is chosen by the mutual consent and consultation of the believers. The first 4 rightly guide Caliphs of Islam were the true vicegerents of Allah(SWT) after Prophet Muhammad (peace be upon him). They were chosen in a democratic way and were accountable for all their errors and mistakes. The first Chaliph of Islam, Abu Bakr(RA) had the following to say after he took over the Khilafa:
O Muslims! though you have made me your chief, I am not the best among you. If someone else among you had taken charge of this burden which you have put upon me, it would have been better for me. If you expect that I should rule you just as the Apostle of God did, then I must tell you that it is not possible. The Apostle received Wahi (Revelation) from Heaven, and he was infallible whereas I am an ordinary man. I am not better than you. Therefore, if you see me walking on the straight road, follow me; but if you see me deviate from it, reprove me. If I do right, support me; if I do wrong, correct me. Obey me as long as I obey God and His Apostle. But if you see that I am disobeying them, you too disobey me.
You have the Qur’an with you, and it is complete. God's Apostle has shown you both by precept and example how to conduct yourselves in this life. The strongest among you all is he who fears God. The weakest among you in my sight is he who is sinful. A people that gives up jihad, loses its honor. Be punctual in saying your prayers, and do not miss them. May God have mercy on you, and may He forgive you all."
According to a hadeeth:
There shall be Prophethood (nubuwwa) among you for as long as Allah wishes it to be among you. Then it shall be lifted up when Allah wishes to lift it up. Then there shall be successorship (khilâfa) on the pattern (minhâj) of Prophetship for as long as Allah wishes it to be. Then it shall be lifted up when Allah wishes to lift it up. Then there shall be a trying kingship (mulkan `âddan) for as long as Allah wishes it to be. Then it shall be lifted up when Allah wishes to lift it up. Then there shall be a tyrannical kingship (mulkan jabriyyatan) for as long as Allah wishes it to be. Then it shall be lifted up when Allah wishes to lift it up. Then there shall be successorship on the pattern of Prophetship. Narrated from Hudhayfa by Ahmad with a sound chain as stated by al-Zayn in the Musnad (14:163 #18319) and as indicated by al-Haythami (5:188-189):
There are two kingships that Quran talks about, one that is the kingship awarded to the pious people by Allah(SWT) like Prophet Dawood(Peace be upon Him), Prophet Solomon(Peace be upon Him), Dul-Qarnain etc., which is equivalent to Khilafa since all those pious people were acting as the vicegerent of Allah(SWT) and hence spread peace and justice on this earth. The other type is the one that is obtained by force, violence or by family association like Pharoahs of Egypt etc. The monarchs that I refer to are the ones that belong to this 2nd type. Islam believes that the people who are chosen to be the leaders of the Muslims (Ameer-ul-Momineen) should be the most pious among them and ever ready for his accountability in case of an scandle. The monarchs, however, were known from history to be the ones who basically ran the kingdom as their own property and tortured and killed people based on their own desire. They are not the ones to be confused with the vicegerent of Allah(SWT) since those monarchs will be judged much more severely then ordinary people in the hereafter as they exploited their position by their false desires of lust and word domination.