The pool's mining server gives each miner a template to use for generating blocks. When the server wants to update which transactions are included or which block to build upon it will push a new template to each miner.
To generate work for itself the miner is allowed to change the nonce, the timestamp and the extranonce.
The nonce is just a 32-bit number with no special meaning. All possible nonce values are quickly scanned by modern bitcoin ASIC hardware, so with the same timestamp and extranonce you only have a tiny amount of work.
The extranonce is part of the generation transaction, the transaction that generates new coins, which is the first transaction in the block. The extranonce has no special meaning.
The server must never send out the same block template twice, to ensure that the same work is not done multiple times. In the stratum protocol the extranonce is split in extranonce 1 and extranonce 2. Extranonce 1 belongs to the server and is in a part of the block template that the miner is not allowed to modify. To prevent sending the same work twice the server must never reuse the same extranonce 1 value unless something else (that is not modifiable by the miner) in the template has changed. For example the other (non-generation) transactions, or the previous block (the block we are building upon). As part of the template the server will tell the miner how large the extranonce 2 should be, usually 4 bytes. When the miner has tried all possible nonce values it can generate new work by changing the extranonce 2 value.
The timestamp (known as ntime) can also be useful to generate work. This can reduce the work load on a slow controller feeding work to fast ASIC chips. The controller only has to generate enough work to keep the ASICs busy for 1 second, using different extranonce 2 values. After that the ntime can be incremented by 1 every second and the same extranonce 2 values reused. This is known as "roll ntime" or "roll time", as the ntime field of the block is rolled forward. The ntime value can also be incremented every second for the purpose of more exact timestamps on blocks without reusing extranonce 2 values.
In this way the server and client cooperate to generate work and the same block is never hashed twice.