He gave that answer because for so long the Catholic church insisted that Earth was the center of the universe and the sun rotated around it.  I'm not excusing his stupidity, just giving a plausible idea as to why.