The answer to this is Atticus is defending Tom against the charge that he has raped a white woman. There are a lot of people who feel that Tom Robinson raped white women just because he is black. It was getting harder for Tom to continue living in Maycomb because people are judging him.
It is only Atticus who have agreed to help save Tom’s life especially since he believes that Tom Robinson did not do anything wrong. Take note that Atticus started to be appointed by the court in order to help Tom Robinson but he slowly learned more details about the man as time went on. They never formed a relationship outside of that.