Some writers tend to split ChatGPT oputput into "correct answers" and "Hallucinated answers". If this is what you are thinking when saying "Is this part of why ChatGPT hallucinates?", then no. The model never knows if what it is saying is correct. It has a probability about how likely the words are to follow eachother, and that is about it.
The temperature changes how these probabilities are calculated, making otherwise less probable words more probable or vice versa.
However, the model doesn't choose the most likely word every time. Instead it rolls a dice to see where it wants to go next. If Cheese is 80% and Cookie is 20% it won't necessarily choose Cheese. It rolls a die, and maybe the outcome lands on the less likely Cookie.
The roll of the dice happen _after_ temperature has affected the calculation of probabilities.
Maybe it is this roll you are thinking of as hallucination?