Batteries are little chemical factories, and when you charge a phone, the electric current causes chemical reactions to happen deep inside your phone.
These chemical reactions tend to heat up the battery, but they work most efficiently when the phone is cool. You can help the phone to charge faster by keeping it out of direct sunlight and in a cool location if possible. If you keep the phone in a case, consider taking it out of the case while it charges — many cases trap heat, which is bad.
In fact, if the phone gets too hot (about 95 degrees), it may stop charging completely until it has an opportunity to cool down.