How can you assess the quality of any solution without a measure of quality, which, in the context of genetic algorithms, is known as fitness function? The term fitness function is due to the well-known phrase "Survival of the Fittest", which is often used to describe the Darwinian theory of natural selection (which genetic algorithms are based on). However, note that the fitness function can take any form, such as
- How well this solution performs in a game? (in this case, solutions could, for example, be policies to play a game), or
- How close this solution is to a minimum/maximum of some function $f$ (more precisely, if you want to find the maximum of the function $f(x) = x^2$, then individuals are scalars in $\hat{x} \in \mathbb{R}$, and the fitness could be determined by $f'(\hat{x})$ or by how big $f(\hat{x})$ with respect to other individuals); check how I did it here)?
The definition of the fitness function depends on what problem you want to solve and which solutions you want to find.
So, you need some kind of fitness function in genetic algorithms to perform selection in a reasonable way, so that to maintain the "best solutions" in the population. More precisely, while selecting the new individuals for the new generation (i.e. iteration), if you don't use a fitness (which you can also call performance, if you like) function to understand which individuals deserve to live or die, how do you know that the new solutions are better than the previous ones? You cannot know this without a fitness/performance function, so you cannot also logically decide which individuals to kill before the next generation. Mutations alone just change the solutions, i.e. they are used to explore the space of solutions.
Genetic algorithms are always composed of
- a population of solutions/individuals/chromosomes (i.e. usually at least $2$ solutions)
- operations to randomly (or stochastically) change existing solutions to create new ones (typically mutations and crossovers)
- a selection process that selects the new solutions/individuals for the next generation (or to be combined and mutated)
- a fitness function to help you decide which solutions need to be selected (or even combined and mutated)
For more info about genetic algorithms or, more generally, evolutionary algorithms, take a look at chapter 8 and 9 of the book Computational Intelligence: An Introduction by Andries P. Engelbrecht.