Theory of stripes in quasi-two-dimensional rare-earth tellurides