KDE Plasma (6) user - Firefox Multiple Profiles.
It's been far too long since I set it up, so I forget if I had to duplicate the application, if you do mine uses these settings:
Firefox Profile Manager
firefox
--new-instance --ProfileManager
I prefer to NOT group windows so I can sort them manually, but also, offhand, because I believe it groups off of the executable name, not the profile.
If you right click on the Icons-and-Text Task Manager Settings, the Behavior tab has TWO options for Group: behaviors [Do Not Group] (I prefer this anyway) or [By Program Name] which I take to mean the executable. I'm not sure if it follows symlinks, but if that's an issue you can probably make a script to hardlink instead. A couple firefox-profilename applications that point back to firefox should work. You can even make a custom version of the launcher that invokes with a specific profile ID rather than selecting one.
As a further set of asides:
Firefox please 1) It'd be nice if firefox renamed it's arguments list to prefix it with the selected profile ID as the first item.
KDE Plasma please 2) It would be great if the grouping thing could be expanded to E.G. consume the program name + first two tokens of the arguments. Maybe with a customization per group.
KDE mega _please_ 2.b) Or even just to call an external program with a window ID handle and have it write back a string that's used as the group 'name'.