The shape of dark matter haloes in the Aquarius simulations: evolution and memory