Confusion about independent and identically distributed? Say that I wish to measure the height of male within the population (so gender=Male is the only factor I am accounting for). Say I collect 100 observations of male height from an elderly population. This is not representative of male heights because it is heights of males of a particular age range. Since my sample age may differ from the population average, if i derive a MLE, then it will be completely different to the population parameter.
Am I violating the assumption that my random variables are iid?

Your random variables are still iid, or at least they could be if they are independently chosen from heights in that same elderly male subpopulation.
The properties of the MLE will depend on what the distribution is in that subpopulation.  Suppose that the distribution of height is Normal in the population and also Normal (with different mean and variance) in the subpopulation.  The MLE based on your sample will estimate the subpopulation mean and variance. It will have all the nice properties guaranteed for MLEs in iid samples as an estimate the subpopulation mean and variance.  It won't be a good estimate of the population mean and variance, because those are different.
You're not violating the assumption that the sampled random variables are iid; you're violating the much more basic assumption that the distribution of the sample answers your research question.
