If you build a model before seeing the data you are more likely to get results (effect sizes, p-values, etc.) that correctly relate the variables in the model to the process you are studying. That is, your model should generalise fairly well to future observations. However, this model may be next to useless in practice if the variables you fitted don't explain much of the variation.
If instead you build the model after seeing the data, i.e. in a data-dependent strategy, you are more likely to discover things you didn't expect but you will also overestimate their effect size.
For example, before seeing the data you decide to fit "sex" as covariate when in fact sex has no effect at all. If you decide to follow up results with smallish p-value, you have, say, ~1/20 (i.e. p < 0.05) chance of obtaining a seemingly interesting result that is in fact a false positive.
But if you allow yourself to fit covariates after seeing the data you are guaranteed to find something with small p-value. If it's not sex, try something like year of birth, age, whatever. If "age" does have an effect you will be able to pick it up with this strategy, but you are likely to overestimate its effect because if the effect is small you would have not noticed it in this dataset.
If you are familiar with R or some other language try this experiment: simulate a treatment vs control experiment with small effect size for "treatment", test using for example a t-test. Repeat many times, like 10000, and keep only results with p < 0.01. The difference between means of these selected experiments will be, on average, larger than the ground truth from your simulation.
In my opinion, building after seeing the data is acceptable, even essential for research to progress, provided you are aware of these drawbacks. Also, ask yourself whether you have a plausible explanation for a variable that you have considered only after seeing the data. When you present results state whether you built the model before or after seeing results. It would be very misleading to report that your hypothesis was that "age" has an effect, then you looked at the data and, yes!, the effect is there. In fact you came up with that potentially interesting hypothesis only after seeing the data.