Aims. Studying the effects of an inhomogeneous interstellar medium (ISM) on the strength and the shape of the Lyman alpha (Lyα) line in starburst galaxies. Methods. Using our 3D Monte Carlo Lyα radiation transfer code, we study the radiative transfer of Lyα, UV and optical continuum photons in homogeneous and clumpy shells of neutral hydrogen and dust surrounding a central source. Our simulations predict the Lyα and continuum escape fraction, the Lyα equivalent width EW(Lyα), and the Lyα line profile, and their dependence on the geometry of the gas distribution and the main input physical parameters. Results. The ISM clumpiness is found to have a strong impact on the Lyα line radiative transfer, entailing a strong dependence of the emergent features of the Lyα line (escape fraction, EW(Lyα)) on the ISM morphology. Although a clumpy and dusty ISM appears more transparent to radiation (both line and continuum) compared to an equivalent homogeneous ISM of equal dust optical depth, we find that the Lyα photons are, in general, still more attenuated than UV continuum radiation. As a consequence, the observed equivalent width of the Lyα line (EW obs (Lyα)) is lower than the intrinsic one (EWint(Lyα)) for nearly all clumpy ISM configurations considered. There are, however, special conditions under which Lyα photons escape more easily than the continuum, resulting in an enhanced EW obs (Lyα). The requirement for this to happen is that the ISM is almost static (galactic outflows ≤ 200 km s −1 ), extremely clumpy (with density contrasts > 10 7 in HI between clumps and the interclump medium), and very dusty (E(B-V) > 0.30). When these conditions are fulfilled the emergent Lyα line profile generally shows no velocity shift and little asymmetry. Otherwise the Lyα line profile is very similar to that expected for homogeneous media. Conclusions. Given the asymmetry and velocity shifts generally observed in star-forming galaxies with Lyα emission, we therefore conclude that clumping is unlikely to significantly enhance their relative Lyα/UV transmission.