Dogs may dig holes in the yard for various reasons such as seeking comfort by creating a cool spot to lie in, trying to bury something, like a bone or a toy, to hide it for later, releasing excess energy or boredom, attempting to escape or find a way out, or trying to hunt for small animals like rodents that may be living underground.