To counter this I imagine the pirates would identify the freighter most susceptible to taking damage ie the one with the weakest shield generators or has the slowest speed, and focus on it. Possibly concentrate fire on it's vulnerable points, disable engines etc using long range weaponry perhaps. With enough persistence the freighter might be prised away from the convoy.
Thats why you rotate the ship into the centre of the formation when it's taken damage and push a fresh one to the outside, much the same as when huddled penguins swop places to keep warm.
it is possible but usually have to have voice coms, we do it when we are playing World of Tanks as you advance towards the enemy if the tank at the front takes damage you let one of the other overtake it.
This means that all your tanks take damage, but the enemy cannot focus fire and take out one of your guns because rather than being able to do 2000hp of damage to on tank they have to do 6000 to three.
If done well it should work even better with ships that have shields as they will have time to repair and regenerate.
It's hard enough to do it with three tanks though, you'd have to go some to get it right with 30 freighters although the fire coming off all those turrets would be pretty amazing and you wouldn't want to dive in amongst them.