The colour of your teeth is an optical phenomenon. It depends on the thickness of the enamel. The inner layer of the tooth is called dentin, which is yellow in colour. If the overlying enamel is thin the colour of dentin is visible through the enamel giving the tooth yellow colour. I the enamel is thick the underlying dentin is not visible so tooth appears white. The whiteness of tooth depends on the thickness of enamel. Genetic also plays a role. Usually a fair complexioned person will have yellow shade and a dark complexioned person will have white shade. Kindly consult a dentist
he may restore the top yellow layer with lighter shade veneers
or composite resins. If the teeth have become yellow recently it can be due to plaque attached over the teeth, a cleaning would be fine. Paste usually contains abrasives which gives polishing to the tooth, it cant change the colour.