blocks.getSaveElement not working for core/social-link

That code probably does exactly what you wanted it to, and if we look at the database or try to copy the block we’d see the new <div> that was added. But core/social-link is rendered in PHP so it doesn’t matter, and what the code is doing is not portable. When the code is deactivated or the content migrated/imported/syndicated the block will fail validation when opened in the editor.

See here for how WordPress renders that block: https://github.com/WordPress/gutenberg/blob/trunk/packages/block-library/src/social-link/index.php

To wrap it in a div you need to do it in PHP by filtering the rendering of that block, not in javascript. Though there’s a very very high chance that what you’re trying to do is both unnecessary and bad practice.

For example, what the code is trying to do would be better done with a group block, then added as a block pattern. If you need to modify the core blocks that implies a mistake or a misunderstanding.

In this case I suspect you’re trying to treat a block as a design unit, rather than a building block. Patterns built out of blocks are what are supposed to be the unit of design, not blocks themselves.