Take a look at these examples from the Collection of examples from discourse.threejs.org .
BufferGeometryIndexed
BufferGeometryNonIndexed
RoundedRectangle
RoundEdgedBoxFlat
BeginnerExample step 12
A little more complicated:
Curved2Geometry
see
function BasicGeometry( radialSegments, heightSegments, withTop, withBottom ) { ...