The VIN doesn't contain the engine code or number - it contains the chassis number, as it is stamped onto the chassis.
A manufacturer may have records that will tell you what engine the car left the factory with. They may or may not charge for this. There are also some sites that will deliver you a similar report, again for money.
Can your friend not locate the number stamped on the engine itself? It isn't too hard to find. Otherwise, what about the build
sticker, in the boot or on the service book?