I have had pets throughout my entire life. Based on my having pets and how they have made me feel, and also having family pets and how they have made my children feel, I do believe that pets can improve mental health.
I remember when we lost our family cat, Smokey, back in 2022. She was a year older than my youngest son, so he basically grew up with her, and it hit him pretty hard. He also has autism.