What happens when an image is compressed by thresholding (choosing a suitable threshold and setting the values below the threshold to zero)? Setting the values to zero doesn't mean removing them. They still need to be coded to to be stored or transmitted over a channel, and thus no reduction in the size of image occurs. Is my understanding correct? Are there any steps following the setting to zero step (example Huffman Coding) is performed in order to reduce the number of bits required to encode the image?
Thresholding alone cannot perform data compression. You need to employ some encoding strategy to discard those ignored coefficients, to achive actual bit reduction.
For example, in lossy JPEG image compression, quantization of DCT coefficients helps you reduce the number of states the variables can take; hence reduce the number of bits necessary to encode the codebook.
Thresholding is applied after quantization, and sets a number of coefficients to zero. Typically, consecutive groups of coefficients tend to go to zero together, especially after zigzag scanning pattern. In effect, for a typical nonzero DCT coefficient, there will be a tail of zero coefficients following. Then instead of individually storing each coefficient alone, you define some special symbols for every 1-nonzero-K-zero combination, and store the codeword instead. This is a variant of run length coding (RLC), and is the very step where the actual bit-reduction happens.