The other day I bought a lotto ticket. As far as I know it wasn't a winner. I checked with the machine at the store and it wouldn't read it so the lady at the counter said that she could check it on her side. She did said it wasn't a winner. Ok. But she didn't offer the ticket back to me and it didn't look like she tossed it in the trash. So I am wondering if it really wasn't a winner. I know it wasn't the big winner but I might have won 5 bucks or something. This sort of thing happened to me with a pickle ticket. I had won a a hundred (can't prove it). I asked the waitress to check it for me she brought back a dollar. Now I didn't know better at the time because I didn't play pickle tickets so I didn't question it until I played more often. To late to get that money back. So next time I have a ticket checked I will ask for the ticket back.
You do not need to have a cashier in a store check your ticket. You can check them online. Your state should have a lotto site. You don't say what the lotto ticket was. If it is one of the country wide ones you can also check those online. You can type in the ID number of your lottery ticket and it will tell you if you are a winner.
Some states have a second chance drawing and you can create an account and enter the losing tickets in and you get points you can use to enter other drawings. A lot of people who work in gas stations get people to give them losing tickets and they enter them online.
Most likely your ticket was not a big winner. You should have been able to tell by the sound the machine made when she scanned it. IF it were a winner it makes a different sound. And if it were a big winner and she kept it she could go to jail. You usually do have to ask for the tickets back otherwise they just toss them or keep them. I ask for my gift cards back even when they are suppose to be empty and check them again when I get home. I had a cashier at Walmart scan a $25 card but she only took $2.50 off the card. I had 4 cards total I had given her. And I knew the total did not sound right but anyway. She tossed the cards in a basket and got huffy when I asked for them back. So you are right in thinking you should always ask for your supposed losing tickets back. But in the future go online and check the ticket yourself if the scanner in the store does not work.