I don't recall him ever actually being called anything but names by Dr. Smith.
He was usually referred to as just "Robot", but officially named Robot B-9.
I remember (watching the show in reruns as a kid) the robot as the "B-9 Environmental Control Robot". On his "packaging" (a box or a metal cabinet, I think) you can see the name G.U.N.T.E.R., which is an acronym for "General Utility Non-Theorizing Environmental Robot"
His name was "Robot". Just to nitpick, in the second season episode "Ghost Planet" he is referred to as "Robot B-9." In every other episode he is addressed merely as "Robot."
In an episode where they travel back in time to just before they launch, there is a crate in Dr. Smith's office. It contains the Robot. On the side there is an acronym, G.U.N.T.H.E.R., which stood for General Utility Non Theorizing Environmental Robot. But as others have said, they always referred to him as Robot. Some people think his name is Robbie, but that is only because he was designed by the same person: Robert Kinoshita. Originally, Robbie was supposed to be the Robinson's Robot, but Irwin Allen could get him for filming the new material added to the pilot footage. Robbie was a busy robot actor back then and made many guest star appearance on various TV shows-including eventually Lost in Space, first as the Robots' adversary, in "War of the Robots" and later on in "Condemned in Space."
There was one episode where a sentient robot referred to him as B-9. In the script, they often referred to him as 'hero'.
Some of the information contained in this post requires additional references. Please edit to add citations to reliable sources that support the assertions made here. Unsourced material may be disputed or deleted.
Robby the Robot was actually a Robot on the film, "The Lost Planet". That same Robot featured in season 1 episode 20, where the Robinson's Robot got very jealous of a Robot they found, which happened to be the same Robot used as Robby the Robot in The Lost Planet.