The purpose of a traffic stop is seldom due to traffic infractions. Traffic stops are an access vector, or as police call it, a point of contact.
If a patrol officer is tasked to pull over someone by an investigating detective, their sergeant, or anyone else out ranking them, that's what they are going to do. They all have ranks and respond to higher authority. It's part of their job.