A good translator can find a comparable idiom that neatly replaces it in the target language, but it is rare to have idioms that match
exactly in their applicable scope. It depends on the context, on the tone of voice, on the age of the speaker, on other visible or hidden social classifiers, even on the region the original speaker hails from.
This is something humans (i.e., experienced translators) excel at. It is something computers cannot do except at a very basic level — they lack the cultural knowledge and autonomous connection making capability needed.
In Dutch I could translate 'not my cup of tea' in many ways depending on the context. Some examples:
Neutral translation in lieu of additional context: „Dit is niet naar mijn smaak.”
Young person in a social context: „Dit is niet echt mijn ding, nee.”
Middle age manager in a white collar office environment: „Nee, dit is 'not my cup of tea', zeg maar.”¹
Ironic and/or cynical down-to-earth jocular fellow: „Dit is niet mijn kopje thee.”²
1: Note the literal borrowing of English.
2: A literal translation used humorously, knowing full well that this is not 'correct'.