The question completely lacks insight into Kant's political theory. The categorical imperative has nothing to do with politics.
What is politics? In The Perpetual Peace (Appendix 1), Kant writes:
there can be no conflict of politics, as a practical doctrine of right, with ethics, as a theoretical doctrine of right.
If politics are to be morally just, then there can be no gap between what morals demand and what politics demand. While the individual is obligated by the moral principle, the categorical imperative, it doesn't apply to the government, which is an artificial person. Even if the government consists of only one person, the monarch acts not as an individual, but as the executive authority (ideally speaking, in theory), and as such, other demands are made to their actions. Right concerns only with external actions, that means the actions between individuals. An action is right if it can exist with everybody's freedom as a universal law (Metaphysics of Morals). While the categorical imperative demands that you apply it to your actions out of duty, right does no such thing - you can act right or not, but you must be prepared that others will coerce you, if you don't (which is impossible for internal actions). What I'm trying to show is that the actions of the government, even if it consists of only one individual, are external actions, therefore they are evaluated in aspect of legality, not of morality (in the narrower sense), and as the execution of a state, the government doesn't necessarily have to be following the categorical imperative to be executing right.
We then have to ask what kind of government Kant advocated. He wrote a lot on that, and again, the Perpetual Peace gives insight (First Definitive Article):
The Civil Constitution of Every State Should Be Republican;
The only constitution which derives from the idea of the original compact, and on which all juridical legislation of a people must be based, is the republican. This constitution is established, firstly, by principles of the freedom of the members of a society (as men); secondly, by principles of dependence of all upon a single common legislation (as subjects); and, thirdly, by the law of their equality (as citizens). The republican constitution, therefore, is, with respect to law, the one which is the original basis of every form of civil constitution.
As the SEP writes on Kant's Social and Political Philosophy:
“There is only one innate right,” says Kant, “Freedom (independence from being constrained by another's choice), insofar as it can coexist with the freedom of every other in accordance with a universal law” (6:237). Kant rejects any other basis for the state, in particular arguing that the welfare of citizens cannot be the basis of state power.
As to be free means to follow one's own rational principles, only the individual living in a civil society with rational laws (i.e. laws the individual would agree with) can be called free. As Kant advocated a republican constitution, not a democracy, how would the sovereign or the government know about what laws the free citizen of the state would agree to? Kant "invents" a touchstone to answer that question, the touchstone of Publicity, again in the Perpetual Peace (Appendix II, note that there is a strong resemblance to the categorical imperative in the formulation and the universal demand):
This principle is to be regarded not merely as ethical (as belonging to the doctrine of virtue) but also as juridical (concerning the right of man). A maxim which I cannot divulge without defeating my own purpose must be kept secret if it is to succeed; and, if I cannot publicly avow it Without inevitably exciting universal opposition to my project, the necessary and universal opposition which can be foreseen a priori is due only to the injustice with which the maxim threatens everyone. This principle is, furthermore, only negative, i.e., it only serves for the recognition of what is not just to others. Like an axiom, it is indemonstrably certain and, as will be seen in the following examples of public law, easily applied.
I'm probably overseeing argumentational gaps. If there is something missing, I will gladly add that.