Total cost is the entire cost of making a good or service. It includes both fixed costs and variable costs. Fixed costs are costs that do not change when the amount of products made changes. For example, imagine that you have built a factory and supplied it with many sewing machines so you can have people sew shirts. The cost of the factory and the machines are fixed costs because they are the same whether you make 0 shirts per day or 1000 shirts.
Total costs include fixed costs and variable costs. Variable costs are the costs that change as output changes. In our shirt factory, the wages of the workers who make the shirts will be a variable cost. So will the cost of the material from which we make the shirts. These are things that would be much lower if we made 0 shirts than if we made 1000 shirts.
Marginal cost refers to the cost of making the next unit of output. If it costs me $99 to make the first 99 shirts of the day and $99.25 to make 100 shirts, the cost of the last shirt was $.25. That was the marginal cost of making that shirt.
So total costs include all costs. Variable costs only include costs that change as the level of production changes. Marginal cost refers only to the cost of making the next unit of output. This is how the three differ.