A letter of interest is a message you send to a company you want to work for, whether or not they have posted an opening that matches. It is a bet that a company you admire has needs it has not gotten around to posting, or will have soon, and that reaching out directly puts you ahead of whoever waits for the listing to appear.
It works because it is rare. Most applicants only respond to postings, so a genuine, specific letter of interest stands out simply by existing, especially at smaller companies without a large recruiting team screening every inbound message.