Each output carries a small program that sets the spending condition: one signature, two of three signatures (multisig), or a time lock.
Where you learn this
Class 7.1: Satoshi's design and how Bitcoin transactions work, in Module 7: Bitcoin: protocol, nodes and Lightning.
