From what I gather from here (
https://www.jclinepi.com/article/S0895-4356(08)00157-1/fulltext), it seems like the underlying cause of sensitivity/specificity changing with prevalence is because of patient characteristics that complicate administration of the test. For instance, if a 20 year old with CAD is administered a clinical test and the result is positive, you're may be more likely to attribute that to the underlying CAD versus if you administer the same clinical test to a 70 year old and it's positive, you may be more likely to chalk it up to comorbidities, etc. So there is no direct link between prevalence and sensitivity/specificity - just that they may vary together due to a shared underlying mechanism. Is that roughly correct?
Also, if you're taking USMLE, I would assume that sensitivity/specificity are invariable across prevalences.