He may be squatting in it ... but does he legitimately hold the office it represents?
Who's the Pope?
According to St Robert Bellarmine, Doctor of the Church, no:
Therefore, the true opinion is the fifth, according to which the Pope who is manifestly a heretic ceases by himself to be Pope and head, in the same way as he ceases to be a Christian and a member of the body of the Church; and for this reason he can be judged and punished by the Church. This is the opinion of all the ancient Fathers, who teach that manifest heretics immediately lose all jurisdiction..."