This sentence sounds slightly awkward in English. We would normally use the preposition 'to' in this case; giving 'I have not been to Odesa'.
So in English, 'to' is used for going to somewhere. Examples are: I am going to the cafe; I am going to the shops; I am going to court; I am going to work (work being a noun).
in this sentence, the case is the indirect object in English. But it is the locative case in Ukrainian. This can lead to problems translating between the two languages, so we have to be aware of these differences.
Currently the versions with "in" and "to" are shown with equal frequency i.e. one or the other time you get this exercise from Duo, either "in" or "to" will be displayed randomly.
I guess the reasoning is exactly what you said :) On one hand, "to" is more natural; on the other, "in" is the literal translation...
Одесу is the Accusative case, used with the locations that you go to. Here is the Locative case, there is no verb of motion. It is moving vs being/doing something
Вчора я був у Бостоні (Loc.) - Завтра я їду в Бостон (Acc.). Yesterday I was in Boston (where at?) - Tomorrow I'm going to Boston (where to?)