Actually, inventing 'god' is incredibly intelligent. Consider the most ignorant people on earth, not stupid, ignorant, now watch their reasoning:
They see that they infilict order upon nature -> they see they are ordered (as in their body)-> they assume they were created -> they see that they have the power to destroy their creations -> they try to make friends with their 'creator' -> they dream -> they notice a sleeping person is similar to a dead person -> they assume death is a permanent dream or what have you. (Later when the race has evolved a few generations and they are a little less ignorant) they 'know' that 'god' is watching over them -> this makes them feel comfortable -> feeling comfortable is good -> keep feeling comfortble.

Oh and plus; the wise-woman of the village said that god exists so he must exist. This is the wise-woman we're talking about here.