It works the same way any radar works. An antenna broadcasts a pulse of energy and listens for its reflection and interprets the power of the reflection to calculate the reflectivity factor Z, expressed in decibels dBZ (helpful because return power varies across many orders of magnitude). Weather radar can see water, hail, bugs, birds, bats and bigger things, and the ground but not clouds. Higher return power can mean more objects or bigger objects. A basic single-polarization radar cannot tell the difference between a tons of small rain drops and a fewer big raindrops.
The particulars of the radar on any aircraft are generally going to be determined by the antenna size, as the optimal frequency of emission varies for a given antenna. The large S-band* dishes that make up the ground based WSR-88D network are quite big (around 10m). S-band is a good choice because they have low attenuation and can penetrate through storms and see things behind them. Airplanes can't use S-band though, because the antennas are too big to put on the airplane and require too much power to fully utilize them.
Airplane radars are generally in the X-band*. X-band can see smaller particles than S-band but attenuates easier. This means if a big storm is in front of you, the energy doesn't penetrate far into the storm and may not show you the whole storm. These are great short range radars and work well in airborne applications as long as you are aware of the issue with attenuation.
Airplane radar displays typically only display information from the on-board radar and do not downlink any additional information from ground stations. Onboard radar are usually adjustable in the vertical by the pilots, so they can point the radar up or down as needed.
Here is an example of a radar antenna and associated electronics on a Cessna Citation 501:
Image by Dtom, Wikimedia Commons. https://en.wikipedia.org/wiki/File:Cessna501_radar.JPG
*S-band is 8-15 cm / 2-4 GHz
X-band is 2.5-4 cm / 8-12 GHz