#include <bits/stdc++.h>
using namespace std;
bool debug = false;
vector<int> G[(3 * 100000 + 42)];
struct LCA {
  vector<int> height, euler, first, segtree;
  vector<bool> visited;
  int n;
  LCA(vector<vector<int>> &adj, int root = 0) {
    n = adj.size();
    height.resize(n);
    first.resize(n);
    euler.reserve(n * 2);
    visited.assign(n, false);
    dfs(adj, root);
    int m = euler.size();
    segtree.resize(m * 4);
    build(1, 0, m - 1);
  }
  void dfs(vector<vector<int>> &adj, int node, int h = 0) {
    visited[node] = true;
    height[node] = h;
    first[node] = euler.size();
    euler.push_back(node);
    for (auto to : adj[node]) {
      if (!visited[to]) {
        dfs(adj, to, h + 1);
        euler.push_back(node);
      }
    }
  }
  void build(int node, int b, int e) {
    if (b == e) {
      segtree[node] = euler[b];
    } else {
      int mid = (b + e) / 2;
      build(node << 1, b, mid);
      build(node << 1 | 1, mid + 1, e);
      int l = segtree[node << 1], r = segtree[node << 1 | 1];
      segtree[node] = (height[l] < height[r]) ? l : r;
    }
  }
  int query(int node, int b, int e, int L, int R) {
    if (b > R || e < L) return -1;
    if (b >= L && e <= R) return segtree[node];
    int mid = (b + e) >> 1;
    int left = query(node << 1, b, mid, L, R);
    int right = query(node << 1 | 1, mid + 1, e, L, R);
    if (left == -1) return right;
    if (right == -1) return left;
    return height[left] < height[right] ? left : right;
  }
  int lca(int u, int v) {
    int left = first[u], right = first[v];
    if (left > right) swap(left, right);
    return query(1, 0, euler.size() - 1, left, right);
  }
  int dist(int u, int v) {
    int parent = lca(u, v);
    return height[u] + height[v] - 2 * height[parent];
  }
};
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  int n;
  cin >> n;
  vector<vector<int>> V(n + 1, vector<int>());
  for (int i = 0; i < n - 1; i++) {
    int a, b;
    cin >> a >> b;
    V[a].push_back(b);
    V[b].push_back(a);
  }
  LCA LASEK(V, 1);
  int Q;
  cin >> Q;
  while (Q--) {
    int x, y, a, b, k;
    cin >> x >> y >> a >> b >> k;
    int dab = LASEK.dist(a, b);
    int dxy = LASEK.dist(x, y);
    int cycle = dxy + 1;
    int dax = LASEK.dist(a, x);
    int day = LASEK.dist(a, y);
    int dbx = LASEK.dist(b, x);
    int dby = LASEK.dist(b, y);
    bool good = false;
    int zwykla_droga = dab;
    int droga_AXYB = dax + 1 + dby;
    int droga_BXYA = dbx + 1 + day;
    if (zwykla_droga % 2 == k % 2 and zwykla_droga <= k) good = true;
    if (droga_AXYB % 2 == k % 2 and droga_AXYB <= k) good = true;
    if (droga_BXYA % 2 == k % 2 and droga_BXYA <= k) good = true;
    if ((droga_AXYB + cycle) % 2 == k % 2 and droga_AXYB + cycle <= k)
      good = true;
    if ((droga_BXYA + cycle) % 2 == k % 2 and droga_BXYA + cycle <= k)
      good = true;
    cout << (good ? "YES\n" : "NO\n");
  }
  return 0;
}
