Uniswap Mechanics Explained: The Role of Liquidity Pools and AMMs