Although Anakin built C3PO, the droid was just one of many similar protocol droids across the galaxy. Moreover, C3PO had his memory wiped at the end of Episode III. Thus he would not have remembered anything about Darth Vader or who he ever once was.
The real reason why Obi-Wan Kenobi, the Lars family, or Darth Vader didn't act in the original Star Wars trilogy as though they knew C-3PO or R2-D2 previously is that the prequel trilogy, in which they first meet the two droids, had not been written yet.
The real answer is: When the original trilogy was written and filmed, Anakin Skywalker was not the creator of C3PO. There was no consideration given to who Vader would recognize, because there was no reason for Vader to recognize the droid, at all.
Future of Star Wars
Vader did recognize C-3PO, and R2 quite possibly recognized Yoda, but either couldn't or chose not to inform Luke about him.
Definitely not. As many other have pointed out, C-3PO had his memory wiped at the end of Episode III, so it is almost certain that he does not know.
R2-D2 was present when Padmé gave birth to Leia and Luke, so he knew Luke was Anakin's son – but what he didn't know was that Anakin became Darth Vader. In addition to that, Anakin's fall was surely a painful event in R2-D2's life, one that he definitely wouldn't like to remember or even talk about.
Yoda recognized R2-D2 during The Empire Strikes Back.
Darth Vader can not use force lighting, because of his severed arms. Robotic hands can't summon the force lighting. However Darth Vader can still use other forms of the force, such as force choke.
Obi-Wan Was Pretending He Didn't Know R2-D2
The base assumption of why Obi-Wan doesn't remember R2-D2 -- in light of the prequels -- is that Obi-Wan is feigning ignorance in A New Hope to downplay the importance of the droid's arrival.
Theory 1: Leia Doesn't Remember Ben Is Obi-Wan
Throughout her encounters with Kenobi in the series, he refers to himself as Ben. The most straightforward explanation would be that Leia knows the person who rescued her is Ben, and never connected the dots that Ben is actually Obi-Wan.
In other words, Emperor Palpatine passed a law forbidding droids from translating Sith language specifically because he knew he'd eventually use a secret message to hide his location while recuperating from near-death and plotting his revenge.
C-3PO accidentally became part of the Battle of Geonosis when his head was affixed on top of a battle droid's body after a mishap in the Geonosian droid factory. R2-D2 and C-3PO witnessed the secret wedding between Anakin Skywalker and Padmé Amidala on Naboo.
Vader agreed to help the handmaiden, silently recalling the time he spent with Padmé in the process. In this moment, he was once again Anakin Skywalker, a young man in love who simply wanted to change the world for the better.
Star Wars Characters That Can Understand Droids
While all droids understand Binary, only a handful of living creatures can. Canon characters, such as Anakin Skywalker, whose relationship with R2-D2 is one of the best in the whole series, Rey, Poe Dameron, Hera Snydulla and Kazuda Xiono are fluent in the droid language.
However, R2-D2's memory is not wiped; as a result, R2-D2 is the only surviving character at the end of the saga who knows the entire story of the Skywalker family. Both R2-D2 and C-3PO end up in the possession of Captain Raymus Antilles (Rohan Nichol) onboard the Tantive IV.
After Cad Bane had kidnapped and ransacked the memory of C-3PO and R2-D2 for information on the Senate Building's layout, he only had the incident wiped from their memories to avoid having any suspicion falling on him.
Darth Vader didn't learn he had a daughter until Return of the Jedi, when he stood before Emperor Palpatine. The Emperor's power probed Luke's mind, attempting to goad him to fall to the dark side, and he discovered Leia's existence.
R2-D2 was in on the scheme to keep the secret away from Luke and Leia. He was devoted to the Skywalker family, and at the guidance of Obi-wan and Yoda, he would have maintained that secret in order to help protect the twins.
Grandmaster Yoda himself was capable of summoning force lightning in the form of Emerald Lightning. Galen Marek was an extremely skilled user of this Force power, even after his conversion to the light side, rivaling Darth Sidious.
It's likely Kylo never learned how to summon Force Lightning
From what we learned from the Marvel Comics story on Kylo Ren and his upbringing, along with the information explained and even alluded to in the sequel trilogy — it's entirely likely that Kylo never completely learned how to harness Force lightning.
R2-D2, the indomitable droid and mainstay of the Star Wars series, may be responsible for one more incredible feat: saving Grogu.
Obi-Wan's Early Years
“I was identified as Force-sensitive and taken to the Jedi Temple on Coruscant.” In Marvel's Obi-Wan comic, we get a glimpse at his childhood there as a youngling. He began training under Master Yoda as a youngling until Qui-Gon Jinn chose him as an apprentice when he was 13 years old.
Chewbacca would very likely then have inquired about Yoda from Luke. Although the audience is made aware that Yoda knew Chewbacca before Han Solo did in Episode III, Nothing in the original trilogy suggests that Chewbacca had ever even met Yoda.