Why is my ex-boyfriend upset with me?

I went to my ex-boyfriend to reach out to one of his high school friends who's attempted to commit suicide. When I went to him to reach out to his high school friend, he told me that I put him in a terrible position and put an enormous load on his shoulders. He was very angry that I went to him to do that. Am I in the wrong for going to him to reach out? He helped me so much with my depression and bad habits, so that's why I thought of him to reach out. He made me feel awful for thinking highly of him to help. Why did he react this way towards me? I think he's being selfish.