Countries that are self-sufficient have enough resources to meet the demands of their citizens. Such countries do not need to trade, but there is advantage to be gained by trading. These benefits are three-fold: reduced prices, a tradable surplus, and/or reduced work hours for their citizens.
I will illustrate this principle using two commodities - spice and coal - from two hypothetical countries: Zamunda and Elbonia. For this illustration we need to agree on the following assumption:
There are regional differences between these two countries resulting in differing levels of production. For our example, Zamunda is endowed with an excellent climate for growing spices, thus a single worker can grow three units of spice. In Zamunda it takes two workers to produce three units of coal. Elbonia has large accessible coal deposits allowing one miner to produce three units of coal but the climate isn't quite as suitable for growing spices as it is in Zamunda. Two workers are required to produce three units of spice.
Every person in each country requires both one unit of coal and spices. If we assume that each country is to be self-sufficient in terms of coal and spices the relative share of their economies would be as follows.
Fig 1. For Zamunda, there are two coal workers producing three units of coal for every single worker making three units of spice.
Fig 2. Elbonia has one coal worker for every two spice workers in order to satisfy its internal demand of three units of both coal and spices.
As we can see, both countries are self-sufficient in coal and spice production. They don't need to trade. What follows is the advantage should they begin trading.
If both of the countries were to focus on the particular industry that they were better suited to, then the three workers in Zamunda could grow nine units of spice and the three Elbonians could mine nine units of coal.
Fig 3. Production in each country when resources are reallocated for mutual trade.
They could then exchange three units of spice for three units of coal.
Fig 4. Countries exchange spice for coal.
It is important to note that each country still has sufficient quantities of both spice and coal to satiate internal demand, but that they both now also have a surplus.
Fig 5. The quantity of products in both countries after the trade.
This surplus would increase the domestic supply thus leading to reduced prices. Alternatively, it could be used to trade with another third nation. Lastly, the workers in both Zamunda and Elbonia may choose to work less hours per week and still be able to meet their original demand. Any of these options, or a combination thereof, would be of great benefit to both countries.