Bitcoin mining is how the blockchain is updated with new transactions, as well as how new bitcoins are created. The process itself is a competition to find a number that falls within a certain range. The number must be computed using a hashing algorithm on a new block of transactions and the previous block’s hash. When someone finds a number that satisfies these conditions (also known as “solving a block”), their new block is added to the blockchain and they are rewarded a set amount of bitcoins.
See “How Bitcoins Are Created” and the reference links below for more details.