This is because the camera is looking for points of contrast in the subject in order to lock focus. In low light situations, there isn't enough light to create the needed contrast. So the lens typically zooms in and out trying to focus, but rarely doing so.