Solution 1:

This is not possible. The only things you can do with strings in Minecraft commands is testing for an exact string, storing an exact string, comparing two strings (equal or not) and transferring it from one place in NBT to another. You can not edit strings.

Another possibility to get player skulls would be a loot table, but that only works with either a player name that you specify in the loot table directly or a selector, so a player that is currently online on the server. So you could for example create skulls of the player who threw the item, but not based on the name of the item.