The $ operator returns an expression that denotes the location counter at the start of the source line.
The location counter returned by $ does not change, even if code is emitted for the source line.
A typical use of $ is to compute the size of a string or of a block of memory:
MyString DB "Why would you count the number of characters"
DB "in a string when the assembler can do it?"
MyStringLen EQU $-MyString