Capacity planning is like predicting how many seats you'll need for a party. If you invite too many people, there won't be enough space for everyone, but if you invite too few, you're wasting precious real-estate in the venue :). In the same way, in the cloud, you need to predict how much CPU, memory, and storage your application will need to handle its workload. If you underestimate, your app might crash or become slow, but if you overestimate, you'll waste resources and money.
For example, let's say you're building a web application and you expect to have 10,000 users in the first month growing 5% every month. You need to plan how many servers you'll need to handle this load without crashing. If you don't plan properly, your app might slow down or become unavailable when more users start signing up. This can be done by monitoring the current usage and estimating usage with your growth plans.
In modern serverless applications, it's typically not necessary to do any capacity planning as the infrastructure is elastic and will scale up and down as traffic changes.