When a the faction block is destroyed, a pirate station or ship is sent back to neutral, another thing to note is that pirate stations are trickier than ships because you have to punch through the hull to destroy the faction block, also, when the faction block is destroyed they return to neutral but they also turn into a decayed state, just like derelict stations. While with ships you can destroy the faction block much the same way or you can dock to it with some pesky craft (as far as i know, ships don't attack their docked entities, even if they are enemies), and then make your way in with the torch, which you can buy at any advanced shop via the NPC.
When you reach the faction block, then "torch" it for a minute and then it will be destroyed, but the ship won't go in decayed state.
So yes, you can capture them