In many different code environments' official documentation I see UTF-8 expressed either as upper- or lower- case, and also with and without the dash. Are there any places where one or the other is important to use?
Some places where these strings are found include:

The PHP manual in reference to header() arguments (HTTP headers)
The PHP manual in reference to PHP function arguments
The PHP manual in reference to internal configuration
The MySQL manual in reference to configuration
Python 2 code encoding declaration
Bash locale configuration
HTML meta tags
XML doctypes
This is indeed wildly different. One place will accept only one form; the other place will only accept the other.
Listing here which is correct in which situation is not a good idea - it would be a huge and pointless open-ended list. Simply always look up in the respective documentation which form(s) is/are accepted for the specific situation.
Are there any places where utf8 vs. utf-8 vs. UTF8 vs. UTF-8 makes a difference?