How does pollination actually work?
Pollen has to physically reach the stigma of a compatible flower, germinate, and grow a tube down to the ovule — and almost everything about how a flower looks and smells is an adaptation to getting that transfer to happen.
The mechanics. A flower's male parts, the anthers, produce pollen grains containing the male gametes. The female stigma is receptive and usually sticky. A pollen grain landing on a compatible stigma germinates and grows a pollen tube down through the style to the ovule, where fertilisation occurs. The ovule becomes a seed; the surrounding ovary usually becomes the fruit.
Why fruit set fails. Everything after pollination is contingent: if fertilisation does not occur, there is usually no fruit. A plant flowering freely and producing nothing is nearly always a pollination problem rather than a nutritional one.
The transfer methods:
Insects, attracted by colour, scent, shape and nectar. Petal markings invisible to us guide bees using ultraviolet patterns; flower shape frequently restricts access to a particular pollinator.
Wind, used by grasses, many trees and cereals — which is why those flowers are small, dull, scentless and produce vast quantities of pollen, and why they cause hay fever while showy insect-pollinated flowers rarely do.
Birds, bats and water, in various systems.
Why plants avoid self-pollination. Inbreeding reduces vigour, so plants evolved elaborate avoidance: self-incompatibility where a plant's own pollen fails to germinate on its own stigma; male and female parts maturing at different times; separate male and female flowers; and separate male and female plants entirely — which is why some hollies never produce berries.
What it means in the garden:
Pollination groups in fruit trees exist because many varieties need a different compatible variety flowering at the same time.
Courgettes and squashes carry separate male and female flowers, and cold weather or absent insects means no fruit — hand pollination with a brush works.
Greenhouse tomatoes are self-fertile but need vibration to release pollen; tapping the plant helps.