How does it do it?
PeerBlock consists of two parts - an application, and a driver. The driver is loaded deep into the bowels of Windows, from where it can monitor all network activity and allow/block connections. The application is the part that displays a window, and allows you to control PeerBlock.
At the heart of PeerBlock's functionality are the lists themselves. Lists can be added to PeerBlock as either "Block" or "Allow" lists. If an IP address is on a block-list PeerBlock will prevent this connection from taking place; if an IP address is on an allow-list PeerBlock will allow this connection, even if it that IP address was also on a block-list.