It refers to the number of defensive backs on the field.
In a conventional defensive alignment, 4 defensive backs (two corners, free safety, strong safety) are on the field.
In a "nickel" package, an extra defensive back plays (usually another corner), bringing the total to 5.
In a "dime" package, two extra defensive backs play (either two corners, or, less commonly, a corner and a third safety), bringing the total to 6.
It is rare, but not unheard of for 7 defensive backs to be in the field in "prevent" formation to defend against a "hail mary" pass. In this case, often wide receivers are sometimes instead of true defensive backs because they are often taller.