Store the actual unit in a bank once it receives damage that would otherwise kill it.
Or if references aren't an issue, just bank the stats of the unit and store that instead. Then create a new unit and apply the stats.
I don't think storing the unit itself will break references (in terms of triggers, etc).