Scientists group species by sets of shared characteristics. However, organism evolving from shared ancestors also shared many of the characteristics from that common ancestor so it ends up correlating with evolutionary paths very closely. Hope it help!