It's legal to use Russian as the primary instruction language in schools for the first 5 years. After that, they have to switch to Ukrainian, but they can still continue to teach Russian as a foreign language class (same as English etc).
On the whole, I'd say that Ukrainian language policies are more akin to Quebec. OTOH Turkey has been packing its prisons with Kurds until recently for crimes such as "insulting Turkishness", so no, it's not really a valid comparison. I don't like the laws on this subject in either Ukraine or in Quebec (or really any place that tries to force cultural cohesion), but specifics do matter.
Turkey has done the same thing to Kurdish speakers and most of the West has rightfully condemned their attempts to crack down on the language.