The people sacrificed to demons, not to God. The demons were gods they hadn't known anything about. Those gods were new to them. Their people long ago didn't worship them.