Over a hedge here means that the thing was on the other side of the hedge, and he could see it by looking over the hedge. It implies that the thing was taller than the hedge. For all the good it did, he might as well have thrown a stone at it here means that his spell had no effect on the spider, just as throwing a stone at it would not have stopped it.
New words, one handy idiom, and a 2-minute quiz — delivered to your inbox to keep your streak alive.