Native here. Well, I'm not sure my English is perfect when it's about prepositions (you know, prepositions do not always translate the same).
As for the Portuguese sentence, I can assure "naquilo" (em + aquilo) refers to the activity they work with, not to a place as "em" could suggest.
So, the meaning is they work on that activity they like.
With help from a native english speaker, we both agree that the closest literal translation is: "they work on that which they like", but it's a little weird.
The same sentence could be written in different forms, like
"eles trabalham no que gostam" - they work on what they like
"eles trabalham com o que gostam" - they work with what they like.
But I believe, despite the nuances, they all mean the same (at least in portuguese). Duolingo's version (naquilo que gostam) sounds more emphatic, adds more value to THAT activity they wanted to work with.
In English, "They work with what they like." doesn't refer to an activity, but to things that they work with to perform the activity. (Did they just get some new power tools?) I put "They work in that which they like." as I was trying to be closer to "naquilo" and it was accepted but means something totally different. It means that the field of work that they are working in is that which they like, whether it be a profession, a job, an activity. "They work on what they like." could mean that they are working on something which they like.(Maybe they don't even like the job, but this particular project they do like. For example, if someone works as a mechanic and it may be boring, but one day a Ferrari is brought in to be repaired and they like working on that.)