AT LAST, FINALLY and IN THE END all have the meaning of "after a period of time". However, they're used in different ways.
1) AT LAST is used when there has been impatience, a discomfort or a feeling which was the result of long delays. Its normal position is at the beginning of the clause, or at the end of it, or between the auxiliary and the past participle. After a two-hour delay, Tom's plane has landed at last. When he arrived at last, I was so angry that I refused to talk to him.
2) FINALLY = LASTLY refers to an action that someone has been waiting for a long time and that was difficult to realize. Most of the time the adverb is placed between the subject and the main verb, or between the modal or the first auxiliary and the main verb, and after the verb TO BE when it is the main verb. It can also introduce the last element in a series. Our economy must increase productivity, reduce unemployment and finally develop competition. Some people suggest that some satisfaction, some relief are felt when AT LAST is used, whereas FINALLY could be used either for positive or negative results. LASTLY refers to an element that comes at the end of a long list. We must buy flour, chocolate, butter, eggs and finally/ lastly some baking powder to make a cake for Kym's birthday.
3) IN THE END suggests a conclusion after a long process, a lot of suggestions and changes or some uncertainty. Each of us suggested a different plan for our holiday, but in the end we went to the South of France as usual.
4) AT THE END refers to a position at the end of something. Put a full stop at the end of your sentence. BY THE END, means there's a limit= «at some point before the end». Don't worry! She'll be here by the end of the morning.