The twelfth fret on a stringed instrument is special because it marks the “half way” point of the instrument’s scale length, where the note when fretted will be one full octave above the open note. For example, on the high E string of a standard acoustic guitar, if you fret that string at the 12th fret, the note you get will be E, one octave higher than the open string.
The other important thing about the 12th fret is that it is exactly half way between the nut and the bridge. So if you have a 25-inch scale instrument, the 12th fret will be at 12.5 inches. This can be useful to know if you have an instrument where the bridge has been moved or has fallen off when you were changing strings. Just measure to the 12th fret (right to the middle of the fretwire), and double that, and it should tell you where the bridge should go.
On traditionally made store-bought/factory-built guitars, the twelfth fret is usually marked with two dots or some other marker that is noticeably different from the other fret markers, so it stands out.