signing multiple input raw transaction - algorithm and sighash types
Do I understand correctly that both inputs are to be signed
separately?

yes

So first, we sign the first one, then the second one. To sign an input
we replace scriptSig for this input with the scriptPubKey, that locks
this input. ScriptSig for the other one remains blank. It this
correct?

yes

But in both threads in step 13 something is appended at the end of
transaction. It is called hash code type. What is this? Is this has
anything to do with sighash type byte the one that is appended to the
signature?

yes

What is the correct sighash type for the scenario I described above
(signing inputs separately)? Is this: 0x81 (SIGHASH_ALL |
SIGHASH_ANYONECANPAY)? Or should this be 0x01 (SIGHASH_ALL)?

Use 0x01 (SIGHASH_ALL)