This is easily one of the best features of Aurora, in my opinion. The interface is a mess, though, and very difficult to explain. Just tinker with it until you get it right.
PROTIP: Try to form your task groups exclusively from the naval organization screen. I usually have all freshly built ships put into a placeholder task group by default (usually the planet's PDC task group.) Then I go to the naval organization screen in the task groups window, where I can build a new task group in the proper place, move all of the appropriate ships into it, and finally create the task group using the "create task group from branch only" button.