To put it concisely, the holy family were not refugees. They were citizens traveling and fleeing Herod's edict. But they were always in Roman territory.
Mary and Joseph were not Roman citizens. St. Paul was a Roman citizen born in the Roman province of Tarsus. They were subjects of Herod. And they weren't fleeing from Roman law (which didn't have any direct application in Judea unless Herod's Sanhedrin passed a law under Roman urging behind the scenes) but from the law implemented by King Herod in Judea, which wasn't a Roman territory but a tributary state on the frontier of the Empire that Rome wanted to stay allied as a buffer with the Parthians.
That persecuting regime vis-a-vis the Holy Family existed in the client state of Judea but not in the Empire - hence why the Holy Family fled from Herod's Judea into the Empire.
Since Judea, if it existed today in relation to Rome, would be classed under international law as a sovereign state (albeit one dependent on a hegemonic neighbour, like the UK post-Brexit or a Soviet satellite state), they would definitely be deemed 'refugees' given that they weren't Roman citizens.