When acting as a referee, I frequently find that some of my papers could be relevant to the paper I'm reviewing (let's say, in a tangential manner). Is it reasonable to suggest the author take a look at my paper, or should I avoid this at all costs due to the risk of revealing my identity and sounding that I'm shopping for a citation?
It happens quite often that as an expert asked to review a paper, your own work is relevant. But you are right to be concerned that it might seem gratuitous. So just like it is often the case that papers authored by any member of the Technical Program Committee (TPC) are held to a slightly higher bar at a conference than other papers, to try to avoid the appearance of nepotism, I try to recommend my own papers only if I'm really sure they deserve to be mentioned. Avoiding them at all costs would do a disservice to the publication because important work might be missed.
As an aside, I recently served on a TPC where I contemplated mentioning one of my papers and decided not to. A different reviewer went to great lengths to point out why my work was relevant, and I'm 95% sure the authors would conclude incorrectly that I was the reviewer in question. Meaning: just because you suggest a paper doesn't actually mean someone can be sure you're the one suggesting it!
You show a reasonable sense of caution in posing this question. That is certainly all that is required.
I agree with Fred. When I receive peer review comments for my own papers, it is not uncommon for the reviewers to suggest literature they find relevant. I sometimes assume that the reviewer may be the author of the paper suggested, but I also recognize that the reviewer is, ideally, knowledgeable on the topic of my paper (since he or she was asked to review it) and therefore I do not know for certain.
I think that if your paper is related and would be helpful for the author, then suggesting it is fine. If there are others, you can cite additional works to your own. Then, it would be more difficult for the author to identify you, if that is your main concern.