Cucumbers are insect pollinated and will cross with any other cucumbers or gherkins nearby. You need around a quarter mile isolation to make sure that your plants won’t cross.
It is possible, although fiddly, to hand pollinate cucumbers. Grow plants under a fleece tunnel to exclude insects. Make sure that you exchange pollen between different plants to keep the diversity of your variety.
Cucumbers need to be ripened well beyond the edible stage. They will become much fatter, and green varieties will turn a dark yellow brownish colour, white varieties a paler yellow. Keep for a week or so after picking to let the seeds mature fully.
Scoop out the seeds and surrounding pulp into a jam jar, add a little water and stir well. Leave the jar on a sunny windowsill for 2-3 days for the seeds to ferment. On the third day, fill the jar fully with water, and stir well again. The good seeds should sink to the bottom of the jar, leaving pulp, debris and empty seeds floating on top. Gently pour off the water and debris, refill the jar, and repeat. After a couple of rinses, you should be left with good seeds at the bottom of a jar in clean water. Drain off the water, and spread out on a plate to dry well.
Cucumber seeds will last for several years if dried well and stored somewhere cool.