How can a sender know receiver's public key when creating "Pay To Public Key" tx? When you create a "Pay To Public Key" transaction, you need to know the receiver's public key. How can we know receiver's public key?

You can get public key hash from address like this, but I'm not sure how to get public key.

FYI: scriptPubkey in P2PK
scriptPubKey:  OP_CHECKSIG
In most cases, if you really want to use a P2PK transaction, you would have to ask the receiver to tell you their public key.

You can't determine the public key from the address alone.   The address is a hash of the public key, and hash functions are one-way.  So if all you have is an address, you can't use a P2PK transaction.  

If the receiver has previously had other transactions sent to the desired address, and has spent at least one of those transactions, then the public key was included as part of the spending transaction's signature.  So in that case, the public key is in the blockchain, and you could use it to make a P2PK transaction.  

I'm not sure why you would bother, though.  P2PK transactions are pretty much obsolete, and P2PKH should be used for all normal purposes.