Hello Munkhorgil
Yes, you are correct, TCP and UDP are protocols that operate in the Transport layer of the OSI model. Now what you saw in the Network layer of the Wireshark capture is the following:
In the header of the IPv4 packet, you will find the “Protocol” field. This field contains information about the Transport layer protocol that this particular IPv4 packet is carrying as its payload. This is just information
Don’t confuse the simple mention of the protocol in the IP header with the actual operation of the TCP or UDP protocols. TCP and UDP are Transport layer protocols because they operate on that layer.
I hope this has been helpful!
Laz