This is not the case. In Islam, the election of the head of state is
based on the vote of the majority. Whoever enjoys the confidence of the
majority whether he is a man or a woman is legally eligible for this post.
However, the only debate which may remain is that whether women in general
are suitable for this job regarding their temperament and nature.
Nevertheless, if the majority does elect a woman for this post, no one has
the authority to veto the opinion of the majority.