Can I use user-defined attributes in the attr/prop method?

Can I use user-defined attributes in the attr/prop method?

Hello,

Can I  assign a user-defined attribute to an anchor tag. 

Can I access this user-defined attribute using the .attr/.prop method?