We don't elect a government in the UK, we elect MPs. The Queen appoints the Prime Minister. She could chose who she likes, but by convention she selects whoever can command a majority in the Commons, possibly in coalition. This is usually the leader of the party with the greatest number of seats, but it doesn't have to be,
Democracy? We've heard of it.
-A.