Apple trees, in particular, come on a wide choice of rootstocks - these are identified by a number, preceded by M or MM. If you want a small apple tree for a border, about 2.5m tall, or to train as a cordon (single stem), choose M9 rootstock. M26 is ideal for espaliers (trained flat against a wall or fence) as well as cordons. MM106 is best for a mini-orchard, as trees reach just 3.5m wide, so can be planted closely.
On low-nutrient, sandy soils, dwarfing rootstocks are even less vigorous, so get advice from a specialist nursery. If your soil is really poor, grow the tree in a pot - M27 is best for this, and for training as a stepover (a low-growing, horizontally trained form). It is so dwarfing that the tree will need a permanent stake.
Apples sold as ‘patio fruit trees’ stay naturally small, especially when planted in a container.