Looking at an example from the startup world. Lets say you own 10% of a small company, and someone shows up to make a huge investment, buying 50% of the company at a price that makes the company worth 10x more.
Now you don't own 10%, you only own 5%, but the company is worth 10 times more, so your investment is worth 5x more, even though you have a smaller percentage of the total. Your shares got diluted, but you still earned profit.
Now compare against a blockchain example:
Imagine a blockchain with a market cap of $4 billion.
You own 10%.
An investor wants to invest in the blockchain similarly to how they invest in startups. They want to buy in very rapidly. Over the course of a week, he spends $1 billion mining the cryptocurrency.
This should dilute your shares, and increase the market cap, just like the startup example.
The new market cap $4+$1 = $5 billion
20% is how much they paid, so they should own 20% of the coins.
You only own 8% now, not 10%, but it is worth the same amount as before.