Why do gases have weight? I know that a gas is made of atoms or molecules moving freely in space.
When these particles hit the walls of where they're kept in they cause something called pressure.
But these particles never pile up on each other and push a surface down by their weight so that we can measure it as weight, not pressure.
So why do gases have weight?
 A: Imagine a gas molecule in a closed box bouncing vertically between the top and bottom of the box. Let's suppose the mass of the gas molecule is $m$ and its speed at the top of the box is $v_t$.
When the gas molecule moving upwards hits the top of the box and bounces back the change in momentum is $2mv_t$. If it does this $N$ times a second then the rate of change of momentum is $2Nmv_t$, and rate of change of momentum is just force, so the upwards force the molecule exerts is:
$$ F_\text{up} = 2Nmv_t $$
And the same argument tells us that if the velocity of the molecule at the bottom of the box is $v_b$, then the downwards force it exerts on the bottom of the box is:
$$ F_\text{down} = 2Nmv_b $$
So the net downwards force is:
$$ F_\text{net} = 2Nmv_b - 2Nmv_t = 2Nm(v_b - v_t) \tag{1} $$
But when the molecule leaves the top of the box and starts heading downwards it is accelerated by the gravitational force so when it reaches the bottom it has speeded up i.e. $v_b \gt v_t$. So that means our net downward force is going to be positive i.e. the molecule has a weight.
We can make this quantitative by using one of the SUVAT (see 'Physics For You' by Keith Johnson) equations:
$$ v = u + at $$
Which in this case gives us:
$$ v_b - v_t = gt $$
where $t$ is the time the molecule takes to get from the top of the box to the bottom. The number of times per second it makes this round trip is:
$$ N = \frac{1}{2t} $$
Substituting these into our equation (1) for the force we get:
$$ F_\text{net} = 2 \frac{1}{2t} m(gt) = mg $$
And $mg$ is of course just the weight of the molecule.
A: As stated in other answers, a gas, like all other matter has weight because it has mass. When you think about pressure, it's usually in the context of an example where the pressure exerted on the walls of a container is many, many times larger than the forces created due to weight.
Consider that our atmosphere at sea level has a pressure of about 101,325 Newtons per square meter and density of about 1.225 kg per cubic meter. That means a one meter cube of air will be pushing down on the ground with a force of 101,325 Newtons due to the motion of the gas molecules with about 12 Newtons (1.225 kg x 9.8 m/s/s) because of the weight of that quantity of gas. Although that 101,325 Newtons actually represents the weight of a one square meter column of air reaching all the way up into space.
Another way to look at it: we know that atmospheric pressure decreases with altitude. It might be more correct to say that atmospheric pressure increases with depth because of the weight of the air in the column above it. In the case of Earth, a column hundreds of miles high (although almost all of it is in the bottom 100 miles).
A: Think of the atmosphere as if it were an ocean. You might not think water has weight if you were diving underwater, but obviously when you fill up your cup with water you feel its weight increase. The atmosphere is really just a gaseous ocean on top of the surface. In extension, if you were to light a candle on the edge of a building taller than the Earth's atmosphere (assuming you had an oxygen source), you would see the smoke fall towards the Earth.

But these particles never pile up on each other and push a surface down by their weight so that we can measure it as weight, not pressure.

This is simply false. Gaseous particles do exert forces on surfaces. It's just that the scales we have are designed to subtract the cumulative forces of air particles. If you were to tare a scale in atmospheric pressure and then place it in vacuum, it would give a negative reading because the weight of gases are no longer present.
A: Here is a short answer: Imagine you would have an empty box (i.e. vacuum), that you would put on a weighing scale. It would have some weight. Now, if you would insert some gas into it, the measured weight would increase exactly by the mass of the gas times gravity.
Historically, this is quite an important point when they burned stuff (solid to gas) in a closed box on a weighing scale, and figured out that there was no measurable loss of weight.
On a microscopic scale, the explanation (see other answers for details, here's the short form) is simply that each molecule hits the bottom with greater speed than the top of the box, due to continuous acceleration towards the bottom. In fact, this has the side effect that the pressure at the top is slightly lower than the pressure at the bottom. Btw, this difference in pressure just equals the weight of the gas. This pressure difference becomes obvious if the box is very high, let's say ... the height of our atmosphere.
Lastly, the "reason" that molecules don't pile up is that collisions on a molecular level are quite different from collisions of let's say balls at macroscopic scale. At molecular level, there is no net energy loss due to friction or plastic deformation (assuming equal temperature). To phrase it a bit exaggerated: Collisions of molecules are perfectly elastic (not exactly true, but good enough for the point here), so they bounce forever.
A: Because they have mass.
And thus when in a gravitational field are accelerated towards other objects with mass, like the Earth.
A: Do correct me if I'm wrong.
1) The atoms in a solid have little kinetic energy (KE), the atoms in a gas have a lot of KE. 
However, the net force exerted by a gas on a container and the net force exerted by a solid on a container is the same (in the absence of gravity), and in this case, zero, because the forces cancel out. If we were to put two containers, one containing a solid and one a gas (solid and gas has the same masses) in a uniform gravity field, the pressure difference between the top and bottom surfaces of each container is actually the same (Because the number of molecules in both containers are the same, and the average net force on each molecule is just the weight of the molecule. The gas molecules moving upwards will now move upwards at a lower velocity, those moving downwards will move downwards with a higher velocity). The only difference is that the pressure on the sides of the container containing the gas is higher than that containing the solid. 
2)The atoms in a solid are fixed in position and hence always in contact with the weighing scale. The molecules in a gas are usually floating around and only in contact with the weighing scale for a short duration of time (when they collide).
As a result, a solid will apply a constant force on the weighing scale but a gas will only apply force when a molecule collides with the scale. We may wrongly assume that as a result, more force is being transmitted by the solid than the gas. However, if we were to average out the force applied by the solid or gas over time, we will find that they are in fact the same. This is because the gas molecule exerts much more force on the scale when it collides then an atom of a solid, for the same time period.
Edit: Also, the atoms in a solid do not accelerate. The moment they experience a gravitational force, they transmit it to the atoms below them. The molecules in a gas can accelerate, so they are likely to exert more force when they collide. 
