Coffee grounds, unfortunately, do not deter mice. On the other hand, coffee grinds can effectively deal with mice. Although coffee grounds do not deter rats, they help mask unpleasant odors. If you sprinkle coffee grounds in specific areas of your home, such as the garage and attic, they may help to mask the stench.