In some books I saw the Ottomans invented Tahtelbahir in 1719. Is it true ?
The first submarine was developed by Cornelis Drebbel, a Dutchman, in 1620. The first submarine that went into action was the Turtle, developed by David Bushnell in 1776. It went in action, but never sank a ship. The first submarine to do that was the Hunley in 1864. (With the loss of the submarine, and its entire crew).
The first modern submarine that went into service was the Holland, invented by John Holland in 1903.
I disregard earlier inventions, such as that of Alexander the Great, because those are not documented, and non-propelled vessels such as diving bells (or diving clocks). Diving bells are relatively easy to construct, and were in use long before submarines. They are not submarines.
The first Turkish submarine was a Nordenfelt in 1886. I can't find anything at all before. It's not impossible this Tahtelbahir made a submerged vessel, but his wouldn't be the first. That honor goes to Drebbel. Further reading on Nordenfelt here.
The first submarine that was successful enough to warrant widespread adoption, changing the nature of naval warfare forever, was built by John Holland. His basic design is still in use today.
There were underwater vessels built before Holland's design, but none were successful enough to warrant widespread adoption. Arguably, methods to travel underwater date back to the time of Alexander, who was recorded to have dove into the Med using an early diving bell.
Holland benefited from two technical advancements that filled in the missing pieces: sustainable power under water (electric motors and batteries), and a safer (for the crew of the submarine) method of attack, the Whitehead torpedo.
It is now believed that the crew of the CSS Hunley were killed or incapacitated by the underwater shock of the explosion, when the explosive charge detonated prematurely, with the Hunley still next to the USS Housatonic, so an effective military submarine really couldn't have been built before the self powered torpedo was available.
It all depends on the definition of "submarine". By the very same wikipedia page on Cornelis Drebbel, it is now believed the accounts of the time were greatly exagerated and the ship was neither completely submergible, nor capable of independent propulsion, relying on the Thames currents to make the crossing of the river.
Jos cited the Holland submarine as the first modern submarine "that went into service". Without that last clause, other modern submarines were built before, like the one built by Isaac Peral in 1888.