Duolingo should put older/younger and gender markers on these. Technically 남동생 are brothers too.
this question has nothing to do with whether or not the brother is older or younger. so 남동생 shouldn't be reported.
This is the same situation as "자매"
Just as we have the word "sibling" this is the brother form of that basically. It's talking about brothers in general.
just because it has the word 형 in it doesn't mean it's talking about older brothers in this case. it would just be 형 if that were the situation.
Naver dictionary (which i highly recommend everyone to use) gives this sentence as an example
그들은 피를 나눈 형제다
They are real brothers