The process of getting a green card from within the US is Adjustment of Status, filed with I-485. If you are in the US, in status, and have nothing barring you from Adjustment of Status, you can choose to do Adjustment of Status with Diversity Visa, after having paid the DV lottery fees to the Department of State.
One thing you should take into account is that Diversity Visas selected for a given fiscal year can only be issued before the end of that fiscal year (September 30), or the person loses the ability to immigrate on that visa. For Adjustment of Status, that means that the I-485 must be approved by September 30, or the person loses eligibility. See the Diversity Visa section in I-485 instructions, page 39-40:
You and your derivatives may only receive a DV through the end of the
specific fiscal year for which you were selected. USCIS cannot approve
any DV adjustment application after September 30 of the relevant
fiscal year. Beginning October 1, USCIS must deny any DV adjustment
application that remains pending from the prior fiscal year.
USCIS cannot guarantee that it will be able to adjudicate your
application before the end of a fiscal year. Therefore, you are
encouraged to file as soon as you are eligible.