I don’t think that Gandhi really said, “Be the change you want to see in the world,” but he did hold a challenging view of the relationship between means (or strategies) and ends. “Be the change” could serve as a shorthand for his view, if it’s properly understood. It’s not about individual lifestyle choices but about social and cultural transformation.
Since the 1960s in the English-speaking world, political philosophy has focused on defining justice, understood as an end-state, a goal. Political ethics then involves a set of questions about whether various means (e.g., civil disobedience, misinformation, compromise, or violence) are acceptable–or necessary–when pursuing justice under various circumstances.
A century ago, as Karuna Mantena notes, there was a more vibrant debate about political means. The central question was not what constituted justice but whether and when to use party politics and elections, strikes, boycotts, assassinations, or revolutions, among other options. Mantena reads Gandhi as a participant in that debate who developed and defended nonviolence as a cluster of strategies. Moreover, Gandhi explicitly argued that the best way to think about politics was to determine the right means or strategies, not to pretend to define justice.
“Means are after all everything,” Gandhi wrote, in response to a group of Indian political leaders who had issued an “Appeal to the Nation” in 1924. These leaders had proposed a concrete ideal of justice: the immediate creation of a new, independent “Federated Republic of the United States of India.” They argued that this end justified a wide range of strategies. They wanted to “delete the words ‘by peaceful and legitimate means’ from the Congress creed, so that men holding every shade of opinion may have no difficulty in joining” the independence struggle.
Gandhi replied that these leaders had no right to define an abstract concept of justice, such as “independence,” by themselves. The “only universal definition to give it is ‘that status of India which her people desire at a given moment.’” Furthermore, the means used to pursue swaraj (independence, in its deepest sense) had to be good. “As the means so the end. Violent means will give violent swaraj. That would be a menace to the world and to India herself.”
Drawing on Mantena, I would suggest the following Gandhian reasons to focus on means rather than ends. Human beings are cognitively limited and cannot see justice far beyond our own present circumstances. Human beings are motivationally flawed and highly susceptible to various distorting and destructive impulses. Therefore, we must choose modes of politics that channel our impulses in beneficial rather than harmful directions. Forming too sharp a definition of justice (or any of its components, such as national independence) can simply excuse destructive behavior. Consequences are always difficult to predict and control, and trying to pursue elaborate ends is foolish. Finally, how we participate in politics helps to constitute the world. By acting, we don’t merely bring about a result (usually an unpredictable one); we immediately create a new reality just in virtue of our action.
For example, one of Gandhi’s strategies was the khadi campaign: a mass effort to boycott European cloth, wear only homespun Indian khadi cloth, and enlist everyone–of all classes–in personally spinning and weaving their own clothes. The khadi campaign is widely understood as a means to one of the following ends: political independence from Britain through economic pressure, rural economic development, or spiritual education for those who spun.
Gandhi thought of it differently. It was impossible to know whether khadi would affect British policy, but an India full of people who wove their own clothes in the cause of independence would immediately be a different place. It would be more decentralized, equitable, ruminative, united, and free. “Through khadi we teach people the art of civil obedience to an institution which they have built up for themselves.” Khadi was educational, but equally important, it represented an institution that the people had built. Education wasn’t an outcome of spinning, as knowledge might be an outcome of schooling. In khadi, the learning was intrinsic to what Gandhi explicitly called the “public work” of building a new system for textile-production. Gandhi described the political work accomplished by a committee and the “constructive work” of weaving in the same passage, as part of the same struggle. Physical production was an essential component because “awareness is possible only through public work and not through talks.”
For Gandhi, “What is justice?” was the wrong question. Our focus should be on forming groups of people who interact in ways that bring out the best in them. He saw a nation of home-weavers as such a group. We could certainly debate his specific vision of a khadi campaign, but the same general approach can take many forms. For example, Jürgen Habermas represents a dramatically different cultural context and political sensibility from Gandhi’s, but he also rejects instrumental, means/ends reasoning in favor of creating groups of people who endlessly make justice by interacting. It’s just that Habermas’ interactive groups are highly critical, explicit, and discursive, whereas Gandhi’s weavers may be literally silent.
See also: notes on the metaphysics of Gandhi and King; Habermas, Ostrom, Gandhi (II); against state-centric political theory; no justice, no peace? (on the relationship between these concepts); the I and the we: civic insights from Christian theology; the right to strike; and the kind of sacrifice required in nonviolence.
 Karuna Mantena, “Gandhi and the Means-Ends Question in Politics,” Institute for Advanced Study School of Social Science Paper 46 (June 2012).
 Gandhi, Notes, May 22, 1924-August 15, 1924, in The Collected Works of Mahatma Gandhi (Electronic Book), New Delhi, Publications Division Government of India, 1999, 98 volumes, vol. 28, pp. 307-310, I owe the reference to Karuna Mantena, “Another Realism, the Politics of Gandhian Nonviolence,” American Political Science Review, vol. 106, no. 2 (May 2012), p. 457
 See Mantena, “Gandhi and the Means-Ends Question in Politics,” pp. 9-12.
 Gandhi interviewed by Nirmal Kumar Bose, Nov. 9-10, 1934, in The Collected Works, vol. 65, p. 317. I owe the reference to Mantena, “Gandhi and the Means-Ends Question in Politics,” p. 9.
 Gandhi, personal note (1925), in The Collected Works, vol. 32, 262-3. I owe this reference to Mantena, “Gandhi and the Means-Ends Question in Politics,” p.11.