It modifies, sorts, and packages proteins and lipids for transport to other parts of the cell or secretion outside the cell.