Real datasets have holes, and every model has to be told what to do about them.
Most algorithms simply refuse to run with a blank in the table.
The blunt option is to drop any row with a missing value.
That is fine if a handful of rows are affected and dangerous if many are.
Rows are rarely missing at random, so dropping them quietly changes who is in your data.
If income is blank more often for one group, you have just removed part of that group.
Dropping the whole column is reasonable when almost all of it is empty.
Imputation fills the gap instead, and the mean or the median is the usual filler.
The median is safer, since a few extreme values drag the mean around.
For categories the most common value is the equivalent choice.
Every fill invents data, which shrinks the apparent spread and can mislead the model.
Adding a separate flag column that records the value was missing usually helps more than the fill.
The fact of absence is often predictive in itself, since an unanswered question says something.
Fit the imputer on the training split only, or the test set has leaked into training.
More sophisticated methods exist, and a median plus a flag is a strong default.