This is because homographs are words that are spelled the same but have different meanings and often different pronunciations.
While "captive" can be used as a noun (someone who is held prisoner) or an adjective (meaning held prisoner), it's the same word in both cases.
Let me know if you'd like some examples of actual homographs! 😊