The America of the 1930s had much fewer people like the shiftless, immoral Bob Ewell than it does today. Since this period was before the Great Society and the welfare state created in the sixties, people had no choice but to work if they wanted to eat and have shelter. Having worked for everything that he had--be it ever so humble--Mr. Cunningham, who is representative of poor people of the Great Depression, yet has a work ethic and pride. He will not accept the WPA checks as does the worthless Ewell; he refuses to be a parasite of society, even for a short time. So, yes, he is appropriately created.
Because of his manly dignity, Mr. Cunningham pays people in whatever way he can (he gives Atticus Finch potatoes) as he does not wish to be "beholden to anyone," to use an expression of that time. And, it is because of this dignity that Mr. Cunningham possesses that he feels shame when little Scout speaks to him and reminds him of "entailments," for it recalls the kindness that Atticus has shown him. Recognizing that he owes Atticus Finch respect, therefore, Mr. Cunningham tells the other men that they all need to withdraw from the area outside the jail house: "Let's clear out."