The main difference between the explanations of inequality offered by John Rawls and Marx and Engels is that the latter viewed it as the consequence of the rise of the bourgeoisie at the expense of the proletariat, or working class. Marx assumed that the increasing alienation (a consequence of inequality) that would result from this worsening division would inevitably lead to the destruction of the bourgeoisie by the proletariat, and the establishment of a classless society. This, in short, is revolutionary Marxism.
Rawls, writing with the hindsight of over one hundred years following the publication of Marx's major works, recognized that history had not (yet, anyway) proceeded according to Marxian models. Rawls understood the realities of inequality, but sought to frame it as a matter of justice, and not as an inevitable feature of industrial society. He accepted that inequalities would exist, but argued that justice dictated not a class revolution, but a society based on the principle that the least fortunate ought to be cared for through making opportunities available irrespective of one's social or economic situation. Marx would have thought such an arrangement impossible, and even undesirable, as it forestalled the class revolution he thought was necessary to achieve justice.
So, in short, these philosophers all believed that inequality was an undesirable feature of their societies, but where Marx and Engels predicted a class revolution to destroy the system that created these inequalities, Rawls thought it possible to establish (or at least promote) equality of opportunity within a society where economic equality did not exist. Where Marx was a revolutionary, Rawls was a liberal.
Marx and Engels focused on the relationship between the oppressor and the oppressed—that is, they maintained that the world consists of the members of the ruling class, the bourgeoisie, and the members of the subordinate class, the working class (http://www.britannica.com/topic/The-Communist-Manifesto). In their work, The Communist Manifesto, it was stated that the members of the ruling class controlled and expanded their wealth by exploiting the working class, members of which could only work and earn money by being exploited by the powerful. Marx and Engels criticized this system of inequality, and they argued the members of the working class, the proletariat, would unite together and defeat the capitalists. This would result in the workers' society, a classless society, whose every member would enjoy the fruits of equality because no one would be exploited. Everybody would have equal access.
Rawls, on the other hand, was less extreme, and according to him, justice had to do with fairness (http://hubpages.com/education/Key-Concepts-of-the-Philosophy-of-John-Rawls). In his book, A Theory of Justice, he argues that every person should enjoy his or her rights without jeopardizing the rights of other individuals. Most importantly, unlike Marx and Engels, Rawls does justify inequality, but only if the most disadvantaged members of the human society could benefit from it. Therefore, he focuses on the underprivileged and insists that others must make an effort to make the position of the underprivileged more tolerable. There should be no inequality if it will not provide benefits for the poor.
Unlike Marx and Engels' system, the Rawlsian system allows some space for a small degree of inequality in society; however, it maintains that inequality should not be tolerated if the majority of people, despite making an effort, cannot find themselves able to thrive.