It sounds like you might be describing a broken tail. I am glad you are going to a vet because if it is a broken tail, and the blood flow is compromised, your dog might need his tail amputated. It could also be a cyst or an abcess. Hard to tell wihtout seeing the dog. I agree that a vet is the best course of action. Good luck.