Is this taking place before or after the LOTR stuff?
Yeah, this is second age in the show. Super rough and condensed Tolkien timeline:
Years of the lamps - from creation to about 30,000 yrs in - Basically Tolkien's creation myth and the doings of the gods prior to the awakening of the Elves
Years of the trees - From the awakening of the trees of Valinor onward for about 14,000 yrs - Lots of stuff happens here....10K years of detante/standoff between the big bad, and the rest of the gods. Elves awaken so the gods say fuck the big bad and take his ass down to protect the elves, a few thousand years of peace, big bad is released from god jail, becomes fake friends to the Noldor elves, fucks them over and kills their king, kills the trees of Valinor, flees to middle earth
First Age - 500-600 years long - Flight of the Noldor to middle earth for them to bring war to the big baddie (Sauron's boss) but the Elves largely get shit pumped. Men arrive on the scene to mixed results (some side with the Elves, some with Morgoth thus this weird dynamic we see in the Arondir storyline), all sorts of character driven stories that are in the Silmarillion. Ends with the war of wrath where they gods finally get sick of the big baddies shit, and everyone everywhere goes to war to literally kick him off the planet.
Second Age - You are here * - 3400 yrs long in total, and it's kind of hard to lay out the lore chronologically here while making the show seem even remotely consistent...because it's not.
Basically, the men who helped the gods are gifted the island Numenor and become an empire of honourable mankind. The Elves lick their wounds from the wars in peace but start to realize that middle earth isn't their long term home and they're slowly decaying and will have to go west eventually to Tolkien's physical heaven. Sauron shows up around 1500 pretending to be sent from the gods to teach the elves his art (that will delay or reverse the decay!), most high elves (Galadriel, GilGalad, Elrond, etc) call bullshit but the smiths from Eregion are eager to learn (this is the Celebrimbor character from the show's doing for the most part) so they become bros. Rings get made, bros become foes because Sauron is a dick. Sauron reveals himself (he's a shapeshifter who goes by the name Annatar previous to this) and tells Middle Earth to come get that smoke if they want it...the Elves want that smoke and there's a war. Diminished Elves get mostly shit pumped again. Elves tag the Numenoreans in and they come in hard off the top rope, Sauron now apparently realizes that he didn't actually want that smoke and prays for peace. Numerean King is a bit full of himself and "captures" Sauron. Sauron slowly becomes his main advisor, turns the men against the elves and the gods....convinces Men to go to war the gods and that ends exactly as poorly as it sounds like it should. Destruction of Numenor, but some Num's stayed faithful the elves and the gods, they left early and land on Middle Earth as Numenor is getting wrecked. Even the remnant of Numenor is overpowered and they found 2 kingdoms (north and south), one of which is Gondor that you'll recognize from the Peter Jackson films...the other is dead (the witch king kills it later in the 3rd age), but it's seat of the high king that Aragorn is descended from. Spirit of Sauron comes back like 1300 years later....Remnant of the Elves and the Numereans immediately want that smoke again and fuck Sauron's day up. Ring is cut off of Sauron's hand by Isildur which ends the age, ring is lost shortly thereafter and goes missing.
Third Age - Peter Jackson! - Elves continue to diminish, men start to become corrupted but shit is generally peaceful for ~1500 yrs. Witch King (head of the Nazgul, who has been in hiding since the end of that last war) has an army now and fucks up the northern kingdom. Plague depopulates middle earth significantly a few hundred years later, line of kings appears to end a few hundred years after that. What's left of the numereans are now "rangers" in the north. Smeagol finds the ring around 2500ish. Men from the east start to become a problem around this time as well and Gondor is more or less in a constant state of war with them. Bilbo gets the ring around the yr 3000 during the events in The Hobbit. A small pause between that and the events of LOTR.