As long as the U.S. is fighting against Russia Europe (including Canada, Aussieland, and New Zealand) won't care. Which is enough to make the U.N. not care.
Europe is willing to overlook anything with regards to Russia just as they barely said a thing when Zelensky suspended elections recently in Ukraine.
As for what's legal and illegal that's just whatever people decide at that moment rather than it being based in any kind of moral standing. See Ukraine suspending elections, Europe being fine with the brutal crushing of the Catalonia independence referendum, and others.
U.S. shouldn't be there. Neither should Russia in my opinion. But, that's certainly not because I care what the U.N. thinks about it.