The main purpose of a cool down is to bring your breathing, body temperature and heart rate back to normal slowly. For land based activities that have involved a lot of exertion the cool down helps to return your circulation back to normal and avoid getting dizzy (or blood pooling). It also helps to flush out any lactic acid that has built up during a hard workout.
For swimming, if you’ve had a physically demanding main practice then this is an opportunity to cool the muscles down by swimming a few lengths at lower effort levels and also gives the mind a break from the physical challenge.
If you’ve had a technically challenging main practice then the cool down gives you the opportunity to swim a few lengths to consolidate your practice and learning.
You could pick up from the Tune Up/Warm Up and compare how you feel at the finish compared to how you feel at the end.
Choose something technically easy to finish on so that you finish on a positive note swimming well and leave the body remembering what it feels like to swim well.
Try something completely different and typically I use it as an opportunity to practice and swim the other strokes or practice some turns or handstands.
You could also pick something technically hard to give your brain and body a flavour of what might come next.
Considering all of the above I often think of a cool down as a round up, a contrast, a transition or a finisher and these are terms used more frequently in other sports.
As you finish your swim and leave the pool don’t forget to reflect on what you learned, what went well and what you will work on during your next practice.