It would often depend on the religion and it's practices. They could occasionally see some of their gods in another religion, and co-opt them in a way; Egyptian religion was the big one, with most of their gods being compared or equated with others. The Greeks and the Romans did it between themselves; many Roman gods are based off of Greek counterparts, but others were merged or downplayed to further the connections. Polytheistic religions are often pretty good at interacting with fellow polytheistic religions.
Monotheistic/Duotheistic religions often had a harder time, as it mean denying the gods of the Romans and Jews. Herodotus had rather poor things to say about Persia's Zoroastrianism, and both the Jews and Christians were known to have hard times with the Romans.
You might interested in some previous threads on Roman interaction with foreign, non-Abrahamic religions some of which are from the FAQ section on "Religion in Ancient Greece and Ancient Rome" as well as some threads on Roman reactions to early Christianity:
Ancient Rome and non-Abrahamic Religions
Did the Romans think of their gods as Roman gods, or as gods period? (In other words: when the Romans imposed their gods on conquered peoples, was this part of how they imposed Roman supremacy? Or could one worship the Roman gods without reference to Rome -- a universal religion, like Christianity?) - 88 comments, over 12 months old.
This thread attracts several flaired users who also talk about how the Romans equated their gods and foreign gods to each other.
Did the Romans prosecute people of different religions? Ostracize them? - 11 comments, over 1 year old.
This thread discusses the criteria that generally determined which religions were persecuted and which weren't.
Why were the Romans so fervent on exterminating Christians, yet they were tolerant towards other religions in the empire? - 27 comments, over 2 years old.
The commenters in this thread explore what religion and religious practices meant for the Romans and thus relate it back to how the Romans thus interpreted foreign religious practices.
When Romans conquered land, did they interfere with the religion of the natives? - 12 comments, over 1 year old.
This thread brings up a large number of linked references which you may want to read to get a better picture of Roman views on various religions.
How did the Greeks/Romans treat gods of other pantheons? - 5 comments, over 1 year old.
A commenter pulls a quote from a Roman historian to show how the Romans saw foreign gods.
Romans and Christianity
Why did Ancient Rome feel so threatened by Christianity that they felt they needed to execute all the Christians? - 23 comments, over 2 years old.
This thread gives an overview of Roman practices towards other religions and a few brief responses on why Christianity was persecuted at an abnormal level.
If Rome was a generally tolerant society, why did they persecute early Christians, and what finally led so many Romans to convert? - 32 comments, over 2 years old.
This thread goes into great depth on how the Romans and Early Christianity interacted while drawing comparisons to then contemporary Judaism.
Why does it seem that the Roman persecution of Christians was so often haphazard, goal-less and poorly directed? - 4 comments, over 9 months old.
A specialist discusses the actual enforcement of anti-Christian laws through the lenses of Rome's governmental and bureaucratic systems as well as situation on the ground as wide-spread persecution was attempted.