Lukas
Certainly, you are not doing anything wrong. For this situation, I highly recommend you check if the physical lock switch on the SD card adapter.
If this is still not working, you can try "Registry edit + restart". Windows itself can enforce write protection through a registry setting. Even if DiskPart says it cleared the attribute, this overrides it.
Here's how to check:
Press Windows + R, type regedit, hit Enter
Navigate to:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\StorageDevicePolicies
If you see a WriteProtect entry on the right:
Double-click it
Set the value to 0
Click OK
If the StorageDevicePolicies folder doesn't exist, you can create it (right-click on Control -> New ->Key, name it StorageDevicePolicies), then create a new DWORD (32-bit) named WriteProtect and set it to 0
Restart your computer (Registry changes don't fully apply until reboot).
If that still doesn't work, format it anyway. The read-only state might be because the file system is corrupted or the card is showing as RAW. Open Command Prompt as Administrator, then, use the commands below:
diskpart
list disk
select disk X (replace X with your SD card's number)
clean
create partition primary
select partition 1
format fs=ntfs quick
assign
exit
Hope it can work.