He doesn't, at least he didn't at first.
But when Thor accidentally landed on Bill's spaceship, searching for a certain criminal or alien if I remember correctly, Bill saw him as an intruder and attacked. During the battle, Thor dropped his hammer, Mjölnir, and Bill picked it up. "Whosoever holds his hammer, if he be worthy, shall possess the power of Thor." Eventually they stopped fighting and made their way back to Asgard, where Bill challenged Thor for the right to hold Mjölnir. When Odin ruled that the hammer was to be Thor's, Bill was upset. So Odin ordered a new hammer, Stormbreaker, to be made exclusively for Bill. The hammer mirrors Mjölnir in power and functionality, though the shape and color are clearly different.
Also, Bill took up the name Beta Ray Bill and if I remember right, he began rebuilding his homeworld or something.