You don't legally keep the VIN number from the old car, but MIGHT get the donor registration number.
Using a new shell (with receipt) and transferring sufficient parts from the donor should avoid any risk of a Q but it makes sense to clarify what you are doing with the local VLO in advance. Apart from anything else, they have to allocate a new chassis number for the new shell.
They might insist on an SVA (tougher MOT at about £180) and they will want the shell stamped in one or maybe two places with that VIN.
Stamping your old chassis number into the new shell won't look correct and if the feds ever discover it, then you will almost certainly be stuffed on a Q plate at best.