Yes, having a pet and especially a dog can help with depression according to this article. They give us comfort, companionship and affection. They keep us on a regular schedule and give us purpose. They can create a sense of calm in that petting and stroking a dog is soothing to both them and us. They can improve our physical activity. They can improve our social time.
All of these things are good for everyone, but particularly someone suffering depression.
https://www.webmd.com/depression/features/pets-depression#1
Do you have a pet? Do you know anyone with a service animal? Do you think it helps with your mood?