Context. Solar wind fluctuations are characterized by discontinuities. The nature and properties of these structures have been largely studied in the literature, and different mechanisms have been proposed to explain their formation. Aims. We investigate the evolution of Alfvénic perturbations propagating in the inhomogeneous magnetic field of a coronal open-field region, in order to study both the way that small-scale structures are generated and the possible formation of discontinuities. Methods. We constructed a model for the equilibrium magnetic field in a coronal hole. The model represents a potential field with a complex structure: regions of opposite polarity or of only the dominant polarity are present at low or high altitudes, respectively. The evolution of small-amplitude Alfvén waves in the inhomogeneous structure is studied by employing a WKB approach that describes how the perturbation wavevector and the wave phase vary along magnetic lines. Results. We find that small-scale structures form in the perturbation at relatively low altitudes (∼3 × 10 4 km) above the coronal base. An initially monochromatic perturbation develops a steep power-law spectrum with slope α 2.3, which is strongly anisotropic with a predominance of quasi-perpendicular wavevectors. Small-scale structures are localized around separatrices of the magnetic structures. In many cases they contain quasi-perpendicular rotational discontinuities that can propagate to the upper corona, eventually reaching the solar wind. Conclusions. The considered mechanism could be responsible for forming a fraction of the population of discontinuities detected in the solar wind.