Correct. Some states have broad stop-and-identify laws. Some have limited stop-and-identify laws.
What we're talking about is more specific than that, and other statutes are implicated.
If you were operating a vehicle and cop pulls up next you and casually asks about your day, then you don't have to identify, because that's a consensual encounter. If he suggests that you rolled through the stop, even if you didn't, then you're subject to things like implied consent that are attached to vehicle operation.