The literal translation is "He that does this. we help him (= Whoever does this, we help that person)". In sentences like this one, "he" means "whoever" and may refer to a person of either gender. By the way, that is the reason why "he who" is used in the traditional translations of the Bible.
Yes, I understand that "לו" translates literally to "[to] him", but the use of "whoever" implies that the statement could apply to any person regardless of gender. Because Hebrew has no way to account for this ambiguity, the masculine "לו" is used, but in English, "them" (in the singular sense) sounds more natural - although admittedly, the structure of the sentence in general sounds awkward in English anyway. Point is, while "him" is obviously 100% CORRECT and a more direct translation, "them" should also be an accepted answer because it better reflects speech-patterns common to most English-speakers without deviating from the sentence's original meaning.
Here is an example of the use of the gender-neutral “they” from John 3:3 in the 2011 New International Bible. Jesus replied, “Very truly I tell you, no one can see the kingdom of God unless they are born again.” This usage is jarring to those of us who were taught that “no one” is singular, and because “they” is plural, these don’t match up. So the people at Duolingo are probably old school.
Aside from being awkward, I think this sentence is in the wrong exercise. Previous usages of "ש+" in this section were for the addition of independent clauses, but this question seems to be using "ש+" for a relative clause.
Not that I don't mind learning new things, but I thought that might be helpful to know.
...And cue me seeing a bunch of the same type of questions in this section of the exercise.
I think your suggested sentence is incorrect, not unnatural. "Whoever" is the subject here, not the object, since they are the person doing something. It is true that they are also the person "we" are helping, but that clause has its own object, "him". Even if the clause did not have its own separate object, such as in "We help whoever does it", the role of a subject would I believe be given primacy over that of an object, and the use of "whomever" would be wrong.