"I don't like doing homework."
I don't understand this sentence at all, and nothing else in the lesson is even remotely similar. Why not use きらい?
It's hard to parse written all in kana, I think.
を object particle
やる do (this is the plain form of the verb, we can't conjugate it to やります to make it polite because this is not the end of the sentence)
の nominalizer (turns しゅくだいをやる into a noun, the action of doing homework)
は topic/scope of discussion particle
いや disagreeable; detestable; unpleasant; reluctant
です polite copula
Using kanji, it becomes easier to pick out the particles (but then you'd have to know the kanji): 宿題を遣るのは嫌です。Also, やる is usually written with kana alone for this sense. It's a rather overloaded verb, see its entry in jisho here: http://jisho.org/search/%E3%82%84%E3%82%8B
You might have heard the past tense of やる used as an exclamation, やった！ (I did it!)
Although they are the same kanji, adding the hiragana い to the end of 嫌 turns いや into きらい. If you look in dictionaries, いや is translated as "detestable" whereas きらい (嫌い) is translated as "dislike, hatred, fear".
Grammatically these are different, in English at least. "Detestable" is an adjective, describing a noun, like "detestable man". But "dislike", "hatred" and "fear" are actually abstract nouns. They are things that you have, in the same way that you have a dog or a hat. E.g. "I have a fear of heights."
In Japanese, the が 好き / が嫌い (to like / dislike) constructions can be translated as "I have a liking for / a hatred for [the preceding thing]; whereas いや may be more like "It is detestable / I find it destestable."
In meaning there is little difference here, but grammatically there is one, which is likley to change the meaning in other contexts / forms. So, for example, because いや is an adjective - a な adjective - you can use it to premodify a noun [Put the adjective before the noun, as in "A green hat.]
E.g. 嫌な男 is "A nasty man." If you used the きらい version there, it ends up as "A man I dislike" or else, something completely ungrammatical / nonsensical.
So, TLDR, if Duo wanted to be kind, it could have said that the translation is actually "Homework is unpleasent / detestable" rather than "disliked [by me]". Both indicate an opinion anyway.
I just wanted to add that you can have the きらい version in front of a noun, but that only happens when constructing relative clauses. For example:
"A man who hates doing homework" = 宿題をやるのが嫌い男
In this particular sentence, both works and may mean the same. But they are not always interchangeable.
「いや」is to express refusal or non-agreeable (situational ) and 「いい」or「よい」is opposite. On the other hand,「きらい」is non-favorable (in general) and 「すき」is opposite. Example: "Will you marry me?" 「いやです」is appropriate but 「きらいです」is not correct.
No difference between「やる」 and 「する」 in the meanings of the sentence,
I agree; personally I even think it's a better translation than using いや. If it wasn't accepted for you, flag it for the course creators to fix.