You're (understandably) confusing a code fork with a chain fork:
Code fork: taking the source code from one project, modifying it, then offering the result as a new project. This is what the overwhelming majority of altcoins are. For example Litecoin is a five-year-old code fork of Bitcoin. Even though Litecoin's code is nearly identical to Bitcoin's, Litecoin from the beginning created its own blockchain, which shares no data with Bitcoin's blockchain.
Chain fork: taking the blockchain from one project, and adding new blocks to that chain that are not compatible with the chain's original style. Variations of this are soft forks (the block-adding rules are made more strict), and hard forks (the block-adding rules are made less strict). Both this week's BTC-BCH fork and last year's ETH-ETC fork were hard forks.
Complications: obviously, a chain fork requires changes to the relevant code to be able to work, so a chain fork usually comes with a code fork, but not necessarily. For example, theoretically, a completely new code base could be created from scratch in a clean-room kind of environment to add new kinds of blocks to an old blockchain.