We don't really have much information about why William Afton kills children, but I think it's because after The Bite of 87' he couldn't handle but just to kill kids after his son the Crying Child died. If you have anymore clues or theories, just add them a little more down where no one typed.