Pectin is not something you make. It is naturally found in the fruit and will help the jam to set.
The elements needed to make jam set are the fruit, sugar and acid (to make the pectin work).
I have been making apple jam this year and have been using the following recipe:
2700g apples
2200g sugar
1100ml water
3 lemons; juice and rind
5 cloves
1 cinnamon stick
This recipe only uses the pectin naturally found in the fruit.
You can use less sugar if you add extra pectin from a pack. In that case, follow the recipe on the pectin pack.
You have a choice of chopping, peeling and coring the apples first, which will give you small pieces of fruit in your jam, or
cooking the fruit into a puree whole, including cores and skin, which will mean that you need to filter the puree through your muslin to remove them. This will give you a smooth jelly rather than a jam.
Whichever you choose, once you have your puree, you can add the sugar, lemons and spices.
Boil the mixture hard for at least 10 minutes.
Then check for setting by putting a couple of drops onto a cold plate. If the surface forms a skin after a minute or so, the jam should set.
You can then put it into sterile and warmed jars.