Lonely is quite different. It usually means being without anyone else and sad or desolate.
So, it appears that being alone and being lonely have different meanings. Yet, I would offer an independent definition for alone. Yes, it is being without physical company and yes, it is exclusive of anyone or anything else that is physical. Yet it is much more than those.
It is being in the company of I AM. It is living in a relationship with yourself to the point that you do not experience loneliness because you are completely and fully at one with yourself, which is I AM.
This relationship of you with you occurs when you spend time alone so that you may witness what you are to you. You are creating a relationship with you!