Target selector seems bugged when I have custom dimension datapack

Today I was working on my server datapack, in which I created a dimension, then I summoned an entity with Tags:["{test}"]. Then I went to the overworld and executed the command "/execute in minecraft:overworld run kill @e[tag=test] ". When I returned to the custom dimension, the entity I summon in the custom dimension also got killed. Any clue about why this happened?

Oh and this also happened with “in Nerther/in End”.