Because she wanted to be in the military. According to an article I found: "In 1776 and 1861, women had to pass as men to fight — and did so with relative ease. Indeed, even feminine-looking women could exploit conventional knowledge that “if it wore pants, it was male” to pass as men and serve, and lived in environments as austere as those of elite combat units of today. These women earned the respect of their peers, some receiving commendations from their units. When a woman was discovered in the ranks, it was typically after she had been wounded in action."
Hope this helps~!
~[Emototheextremo]