If you like an employer, never underestimate how close you may have come to employment with them.  Hiring needs are ever shifting, and you never know when someone may leave, business may expand, and new openings may be created.  To positively position yourself for the future, a polite response to a rejection is in order.

Send a letter or e-mail, and thank the employer for their consideration and time.  Always remember that to attorneys, time is money, so any time away from client matters is valuable to them.  Showing respect for that will make you a good player in the job search.

Express that you are disappointed that you did not get to work with them at this point, but that if their needs change you would love to be considered for any future possibilities.

That's it.  Short and simple.  Leave a good, upbeat, positive impression.

Realize that the legal community is tight knit and you may cross paths with this attorney again. They may be likely to refer you to other hiring attorneys if you leave this good impression, and they are very likely to reconnect with you when their needs change if you demonstrate your good attitude and unfailing interest in this professional manner.