I think I have one imilar d3 Ruy Lopez game. It was a blindfold game.
Ruy Lopez d3 variation

The move d3 in some of the Ruy Lopez variations is such a deep rooted move. I frankly do not know your ranking or how well developed you are as a chess player to tell whether or not you can absorb all of the idea's behind it.
People have written books about some of the lines with the move d3 in the Ruy Lopez. I could talk for ages writing essays about the idea's in some of the variations that have d3 in it. However, I frankly do not feel like writing a novel about it lol.
So what I will say in a very simple answer is. The move d3 protects the e4 pawn.

6d3 is replacing 6Re1 has the main line in GM chess maybe because marshal gambit, d5 line, has proved difficult to crack.

There are a whole range of openings, maybe rather loosely, called Marshal gambits. They all involving giving up material for initiative so gambit is not so incorrect.
The two lines currently very popular in FIDE 2700 play are
1.e4 e5 2.Nf3 Nc6 3Bb5 a6 4Ba4 Nf6 50.0 Be7 6d3
and
1.e4 e5 2Nf3 Nc6 3Bb5 Nf6 4d3 (This one is avoiding the Berlin endgame after 40.0 Nxe4 etc)
You can pop these moves into database of choice, and filter on rating to get a whole bunch of games. To be honest not sure would do you a whole lot of good. Factly explaining what both sides trying to do is beyond by Fide 2000ish level for example.
Of more value might be getting hold of well annotated games. Carlsen tends to play BxN early a lot. Have a vague notion working with unbalances so created, but confusingly has habit of winning from both sides of these positions. Honestly my advise would to leave such subtle opeings as d3 Ruy lopez's to the professionals, and play something more straightforward.

If someone could give me link to the databases with those openings it would be helpful.
I will be writing a blog about those lines in fact lol. I will link it to you when I finish lol.
However, I already gave you a hint on what lines use d3 as white. Its lines that help protect the e4 pawn.
Such as Early Nf6 lines like the (Berlin Defense)
Other lines are with Bb7 lines. In your diagram black will fianchetteo the light bishop so thats why they play d3 protecting the e4 pawn becuase of all the pressure.
In your last variation thats the Classical variation. They also play d3 their sometimes as well. Just protecting the pawn.
Someone explain me key Ideas of white in these 2 openings and give me some links of databases and other resources in these variations.