To enable or disable collapse/expand (aka folding), check or unckeck Collapse/Expand in the Extras menu:


collapse-expand-switch.gif


By default, only groups and containers can be collapsed and expanded. To turn any cell into a group, select it and press Ctrl/Cmd+G.