If you did not have an employment contract guarantying your job, you may be fired at ay time, for any reason, and a company is not obligated to offer you any new position, even one which matches your old postion exactly. Also, the company is not barred from firing you, then immediately looking to hire somoene new for the job.If the company fired you for a discriminatory reason--e.g. because of your race, religion, age over 40, sex, or disability--then that would be illegal and you may have an employment discrimination claim. But otherwise, as stated, they can do what you describe.It doesn't matter why they said what they did, so long as they did not discriminate. There are, in any event, many reasons why they might have said what they did--for example, maybe a client didn't like you, and they wanted to spare your feeling; maybe you performed poorly,  but they wanted to give you a face saving excuse; maybe they fired you to hire a friend of the boss, which is legal, but which they might still be embarrassed about; etc.