A firm with a given technology makes a choice about how much of each of the factors of production to use to make how much output — and pays the cost for doing so. The question for the firm is how to use its technology and choose its inputs in order to make its profits as large as possible.
The way it does so is to choose its inputs in order to make the costs as small as possible.
The technology shown in the figure is a specific form known as a Cobb-Douglas production function.
If you're wondering why economists think this way, consider profit maximization. In the following equation, profit equals the difference between total revenue and total cost:
A firm can determine what to make and how much to make, but it doesn't have any control over what consumers choose to buy. Therefore, it makes sense that economists model the things that the firm does control — its own costs — and so they assume that profit maximization is the same thing as cost minimization.