The Evolution of Dark Matter Haloes in Mergers