Missing value imputation in (almost) balanced data set Suppose we have a categorical field in our data set with two classes. The field contains 5% missing values. Of the remaining 95% values, 47.4% belong to class A and 47.6% belong to class B.
Normally, we use mode to impute the missing value with the class having the highest frequency. But in this case, since the two classes have almost the same frequency, would it make sense to impute 5% of the values with class B? What would be the best approach to handle such a situation?

In my personal opinion, imputation very often crosses the boundary into "simulating knowledge we do not have" territory. This sounds like it may well be such a case.
My first impulse would be to use three possible values in your categorical field: the two you have and "missing". Then re-train your model. An advantage is that then you can also apply your model to cases where this field is missing "in production".
Whatever way forward you decide on: do a sensitivity analysis. Fill all missings with one category, then with the other. How much do the predictions change? If your method of addressing the missingness (which could be imputation or something else, per above) has a major impact on your evaluation metric, then this a point where you may want to invest more resources - either in collecting the missing data, or in finding some workaround.
