To do this, place the old and new chains next to each other and shorten the new chain accordingly or count the chain links and shorten the new chain to the same number of links. The alternative if you no longer have the old chain to hand: You thread the chain, then put it on the large chainring and small sprocket. The derailleur cage should be vertical when the chain is closed.
For travelling:
Mini tool with riveting tool
Suitable chain lock and/or rivet pin (important: there are different pins and chain locks for 9/10/11/12-speed chains)
In the PDF download you will find repair instructions for chain breakage and chain replacement.