If you attack an enemy city with an army containing only one hero and that hero dies but your attack succeeds then afterwards the hero appears in both the city you just won as well as one of your old cities (where he escaped to and is recuperating). Haven't tried this with an army with two heroes where both die and you succeed but it wouldn't surprise me if they both duplicated.