Yikes… Let’s ignore for a moment those highly complicated tech definitions and semantics:
A “way” is a LINE - that’s really the whole secret 
It is made up of several “nodes” - which are POINTS or dots.
If a line forms a “closed ring” (last point=first point) it’s possible to consider it an area - but only if wished.
Then there are “relations” - which are COLLECTIONS of lines and dots.
That is all there is in OSM.
To keep complexity at a bearable level the servers allows only max 2000 nodes for 1 single line, more are blocked. For fixing, that monsterline must be split into 2 or more parts.
In the beginning I found it confusing, because in real life a “way” is for walking or driving, but in OSM it simply means “drawing line”! (PS: the real-life-ways are called “highway” instead, also slightly confusing for a 30cm path in the grass)
For example a simple house is made up of a closed “way” with usually 4 “nodes”, forming a rectangle.
A street or hiking path consists of a “way” and “nodes” too.
A river as well.
A forest or a lake as well, often needing LOTS of nodes and SEVERAL ways as outer borderlines, depending on their size. And to make things more complicated, forests can have “holes” inside without trees, and lakes can have dry islands in the inside, without water. Such “inners” are of course drawn as lines (ways) too. And they must be “closed rings” too. And because the outer and inner ways of that forest belong together, you need to collect them into a “relation”.
There exist various relation types. Just 2 examples, the one for areas like forests is called “multipolygon”. “polygon” for closed rings with a number of nodes, “multi” for several of those. Another relation type is for long hiking or biking trails, leading over lots of different streets and paths. Those are collected together in a “route” relation.
Areas go like this:
Of course there must be a line around their outer border: a way forming a “closed ring”.
But whether or not that shall represent an “area” depends on how it is tagged:
If you give it a “building” or a “forest” tag or other obvious stuff, the rendering apps will assume automatically this ring is meant as “area” and will paint the inside with a color.
If you give it a “barrier=fence”, they will assume automatically that a fence shall only be painted along the outer borderline, not inside everywhere too. So, no area.
But sometimes it gets tricky: What if a closed ring is given a “highway=pedestrian” tag? Is that perhaps a pedestrian street going in a circle? Or is the whole inner area for pedestrians too? In such cases an additional “area=yes/no” tag must make it clear to the rendering apps.