How can I make player surrounded by enemies with A*pathfinding

I’m using a*pathfinding project to do a RTS game, here is my question, how can I make player be surrounded by enemies, just like in war3. I make enemies as a obstacle when he is closing to player, so wish other enemies can find different way to chase player, but it didn’t display good. I’m wishing for a better solution! thx!

You can spawn enemies from random positions.