We may never know what ultimately happened to Titanic’s captain, but there are eyewitnesses accounts that tell of Captain Smith and the crew struggling to figure out how bad the ship was damaged and how to safely get everyone off the ship- that was never designed for an emergency evacuation.
There have so many theories that speculate what Captain Smith’s last moments were, but we can never know for sure.
Obviously, it’s lost to history.
Among the total chaos it’s not surprising that there’s so many contradictory accounts as people were surely more preoccupied by their survival than the state of the ship.
I like to think that Smith (regardless of what the movie showed of him), was one of the last to leave the ship, went into the sea and tried to help as many people as he could in the water until he succumbed quickly to the icy cold temperatures due to age and stress- he was not wearing a life preserver.
He acted bravely and with dedication to duty and did his job as best he knew how. Sometimes that says enough.
His body was never recovered.
There is no evidence to suggest that he intentionally wanted to drown.

Nobody really knows what happened to Captain Smith or what was going through his mind as the ship sank. Various theories about the sinking have included an Egyptian curse. Yes, there actually was an Egyptian mummy on board! There were, of course, traditions that the captain should always go down with the ship.
Also that it was always supposed to be women and children first. Apparently there was at least one divorce after the Titanic, the grounds being that the husband had survived the sinking! (So obviously he wasn’t the “gentleman” the wife had expected.)
There was a vague, unsubstantiated report of an officer committing suicide. However, if it did happen, no one believed it to be Captain Smith. In at least one film Smith is depicted as wandering onto the bridge toward the end, a little lost and uncertain. It is my understanding that people who knew him, said Captain Smith was a man of action, so that would not have been characteristic.
Nonetheless, while Smith had a long career and was highly respected, he’d never encountered a serious incident at sea. So it’s possible he struggled to deal with the situation as it unfolded. Walter Lord, who interviewed a huge number of Titanic survivors, seemed to view second officer Lightoller as the hero of the Titanic.
Certainly, the movie based on Lord’s book, A Night to Remember, casts Lightoller in an extremely positive light. Lightoller himself went into the frigid water while still trying to save passengers, nearly drowned when he was sucked into one of the funnels, clung for a while to an overturned collapsible lifeboat, then was able to get into another lifeboat.
It is believed that his testimony supporting the White Star line, along with the superstition/stigma surrounding his being a former officer on the Titanic, kept him from advancing to better ships and rank.
As for Captain Smith, there’s an apocryphal story that he swam up to a lifeboat with a child in his arms and handed it to the people inside. As the tale goes, he refused to get on to the lifeboat himself and swam away.
Supposedly Smith was retiring to spend more time with his teenage daughter, but had been asked to take the Titanic on its maiden voyage. I very much doubt he wanted to drown, but the officers on the Titanic knew there weren’t enough lifeboats for the passengers and crew (by far).
I believe many of them worked hard to save lives, knowing there was little or no chance of themselves surviving.
One of the many tragedies of the sinking, however, is that they didn’t load the lifeboats to capacity. At least 500 more people could have survived. Probably more, because the ocean was very quiet that night and the life boats could have been loaded beyond their rated capacity.
That said, in the beginning they had a terrible time getting people to go in the lifeboats. The passengers simply didn’t believe that the ship was sinking. So the crew was trying to balance between causing a panic and creating enough urgency that people would actually leave the ship.