A vitamin is something you need in tiny amounts that you must get from an external source. You make large quantities of your own vitamin D after just a few minutes in the summer sun.
A hormone is a chemical that you make in one organ that travels through the blood stream and has its effect on distant organs. Active vitamin D is produced in exactly that way. From the skin it travels to the liver where it is changed chemically to make it ready for final activation in the kidneys. From the kidneys it travels all over the body to do its work.
In fact, I am so unhappy with the designation of vitamin D as a vitamin, that I have coined a new name for this hormone, proverve. It means that proverve (vitamin D) defends your life.