IMAP cannot operate on a whole thread at a time. Ironically you will hardly notice the difference when operating with the web interface, which is very much thread based, but it can be useful to apply a label to a whole thread if your interaction with GMail happens in Thunderbird or mutt. For example, I have a Google Apps script that adds a label to a whole thread whenever someone CCs me on a bug, so that the entire bug suddenly pops up in the "my bugs" Thunderbird folder, including messages prior to my being added.