If you notice that certain words which should begin with a capital letter are automatically changed to lowercase whenever you type them, the most likely reason is that your iPhone has learned this behaviour over time through its keyboard dictionary and predictive text system.
This can happen when a specific word or phrase has repeatedly been entered in lowercase in the past. As a result, the iPhone may assume that the lowercase version is your preferred spelling and will automatically convert it whenever you intentionally type the word with a capital letter.
In essence, the keyboard is not malfunctioning. Rather, it is applying what it has learned from previous typing habits, whether those entries were made by you or by anyone else who regularly uses the device. Over time, iOS adapts to a user's typing patterns and stores commonly used words, spellings, and capitalisation preferences. If a word has been consistently used in lowercase, the keyboard may continue to suggest or automatically switch to that format until the learned entry is corrected or removed.
You mentioned that when you type the word with an initial capital letter, the keyboard still suggests the lowercase version and inserts it that way. In such cases, there is usually a small "×" (x) next to the incorrect suggestion in the predictive text bar. Tapping this x tells the iPhone that the suggestion is not desired and helps remove the learned preference from the keyboard dictionary.
After dismissing the incorrect suggestion, continue typing and using the correctly capitalised version of the word whenever it appears. Repeatedly rejecting the incorrect lowercase suggestion and accepting the correctly capitalised version helps train the keyboard to recognise your preference. Over time, the iPhone will learn from these corrections and begin suggesting and inserting the word with the proper capitalisation. Once the keyboard has relearned the word, the issue should no longer occur and you should be good to go.
This behaviour is particularly common with names, places, technical terms, abbreviations, and custom words that have been repeatedly accepted in lowercase. If dismissing the suggestion and correcting the word does not fully resolve the issue, resetting the Keyboard Dictionary (Settings > General > Transfer or Reset iPhone > Reset > Reset Keyboard Dictionary) can remove previously learned entries and allow the keyboard to start learning your typing habits again from scratch.