Because Spider-Man doesn't warrant an R rating. Neither does Dr Strange. A Captain America R rated film would have be to heavily reliant on war. Opening scene of Saving Private Ryan type violence.
Other characters, like Deadpool, Punisher, Wolverine... Black Widow included, can be successful, and have been successful in that R rated environment. And yes, I do believe Nat is one of those characters that can succeed with an R rating. It's not necessary. I don't think it's EVER 100% necessary, even for Deadpool, but it helps in some cases.