Organisms can have primitive similarity because of distant ancestry, or derived similarity because of immediate ancestry. Derived similarities in particular allow identification of biological groups. For example, both humans and chimpanzees have four limbs and hair, and they nurse their young, but these features do not tell us that humans and chimps are closely related, because all mammals have these features. They are primitive characteristics that reflect distant ancestry. These same features are derived similarities in relation to other groups.
Hair is a derived feature that separates mammals from other tetrapods.
This means that the immediate common ancestor of all mammals had hair, and no other organism did. This means that it can be very difficult to find the correct tree showing the relationships of a group of organisms. Biologists are continually refining their ideas of the relationships of organisms and, as a result, groups are often redefined or undergo name changes as our knowledge increases. There is always a temptation to take evolutionary trees as representing progress. Evolution does not necessarily mean progress.