Fleas and dogs have a symbiotic relationship. In fact fleas can have this symbiotic relationship with any warm-blooded animal. The relationship is a parasitic relationship.
In a parasitic relationship one organism, the parasite, benefits to the detriment of another organism, the host. The dog is a host, it provides a food source (blood) and shelter (the fur) to the parasite the flea.
As I noted the flea can have this relationship with any warm-blooded animal. Rats, birds, even humans. It is a surprisingly common form of symbiosis.