Ukrainian citizens are no longer allowed to leave freely. Men are not allowed to leave, that seems to be confirmed. According to some sources women working in certain sectors like health care either, not sure whether that is confirmed.
I have no clue, but I wouldn't be surprised if the reality differed from the policy here
But Ukrainians are understandable too, and some men are allowed to leave. On the other hand, there are also some returning home from Poland. Imagine you went to Poland in order to provide for your family and your family is left at home. There are many cases like this. In such a situation going back is often the only option - staying away would only cause constant suffering with you being anxious if your wife and kids are safe at that moment or not, and frantically reading all reports of bombing and civilian casualties.
Maybe such things can be started elsewhere.