I'm not convinced the effect is even true in general, and appears to be false in job/task-related contexts particularly when the boss does the disclosure; according to a recent paper:
It is generally believed that self-disclosure has positive effects, particularly for relationships; however, we predict
and find negative effects in the context of task-oriented relationships. Across three laboratory experiments, we
find that both task-relevant (Study 1) and task-irrelevant (Studies 2 and 3) weakness disclosures, made by a
higher (versus peer) status coworker during an interdependent task, negatively affected the receiver’s perception
of the discloser’s status and consequently undermined the discloser’s influence, encouraged task conflict, and led
to lower relationship quality with the discloser. Peer status disclosers did not trigger these negative responses.
We find support for perceived vulnerability as the proposed psychological process (Study 3). Specifically, higher
(but not peer) status disclosers experience a status penalty after weakness disclosures because these disclosures
signal vulnerability, which violates the expectations people have for higher (but not peer) status coworkers.
These findings provide insight into the effects of self-disclosing weakness at work and the ways in which high
status employees may inadvertently trigger their own status loss.
(Doi link; free full-text from one of the authrors.)
What this study (alas) didn't address is whether a low-status peer would be seen in a more positive light by a higher-status one after a disclosure, like in your last paragraph. So we don't seem to have experimental evidence on whether "sucking up" by (more or less machiavellian) disclosures or even faking less competence (as to diminish perceived threat) works as intended. I suppose the latter is quite contextual. In a hierarchy where the lower status individual could conceivably take the place of the higher status individual (say in a military junta or an apparatchik system) feigning a less threatening attitude (via some but not complete incompetence) perhaps does work. I'm having doubts that feigning partial incompetence does much good to a subordinate in a context where the high-status individual does not see any direct threat to his position (like when hiring a contractor for a non-core task). But this is just me theorizing. More empirical research is needed, as the saying goes. In general, other forms of "sucking up" do seem to work through, with the caveat that while "sucking up" may have a positive effect on the relationship with the boss, it's also likely to have a negative effect on the relationship(s) with same-status peers/colleagures.