The meaning behind the expression is something like this: Pretend that something doesn’t exist/refuse to accept the truth/refuse to discuss something. Obviously if you are cleaning a floor, you should pick up all the dirt. If you are lazy, you sweep the dirt under the carpet/rug trying to persuade everyone and yourself that there is no dirt.